feat(platform): add ScoopInstaller support

Resolves #207
This commit is contained in:
xixu-me committed 2026-03-08 13:05:15 +08:00
1 parent 1ed4de50e7
commit 6f0d7e15f8
6 files changed
+161 -1

No files matched your search

+14 -1
View File
@@ -16,7 +16,8 @@ describe('Platform Configuration', () => {
'npm',
'pypi',
'conda',
'homebrew'
'homebrew',
'scoop'
];
requiredPlatforms.forEach(platform => {
@@ -143,6 +144,14 @@ describe('Platform Configuration', () => {
'/v2/distroless/base/manifests/latest'
);
});
it('should transform Scoop paths correctly', () => {
expect(transformPath('/scoop/Main.git/info/refs', 'scoop')).toBe('/Main.git/info/refs');
expect(transformPath('/scoop/Main/blob/master/bucket/git.json', 'scoop')).toBe(
'/Main/blob/master/bucket/git.json'
);
});
});
describe('Platform Base URLs', () => {
@@ -191,6 +200,10 @@ describe('Platform Configuration', () => {
expect(PLATFORMS['conda-community']).toBe('https://conda.anaconda.org');
});
it('should have correct Scoop base URL', () => {
expect(PLATFORMS.scoop).toBe('https://github.com/ScoopInstaller');
});
it('should have correct container registry base URLs', () => {
expect(PLATFORMS['cr-ghcr']).toBe('https://ghcr.io');
expect(PLATFORMS['cr-gcr']).toBe('https://gcr.io');