fix(cli): allow non-GitHub SCP-styled URLs for extension installation (#13800)

Co-authored-by: Maksym Kursin <maksym.kursin@dkatalis.com>
This commit is contained in:
Maksym
2025-11-26 00:57:53 +08:00
committed by GitHub
parent 2b41263aa7
commit f2c52f777c
2 changed files with 15 additions and 5 deletions

View File

@@ -136,8 +136,12 @@ describe('github.ts', () => {
expect(tryParseGithubUrl(url)).toEqual({ owner, repo });
});
it('should return null for non-GitHub URLs', () => {
expect(tryParseGithubUrl('https://gitlab.com/owner/repo')).toBeNull();
it.each([
'https://gitlab.com/owner/repo',
'https://my-git-host.com/owner/group/repo',
'git@gitlab.com:some-group/some-project/some-repo.git',
])('should return null for non-GitHub URLs', (url) => {
expect(tryParseGithubUrl(url)).toBeNull();
});
it('should throw for invalid formats', () => {