@@ -44,7 +44,7 @@ test.serial('Verify package, token and repository access', async t => {
44
44
t . true ( github . isDone ( ) ) ;
45
45
} ) ;
46
46
47
- test . serial ( 'Verify package, token and repository access and custom URL' , async t => {
47
+ test . serial ( 'Verify package, token and repository access and custom URL with prefix ' , async t => {
48
48
const owner = 'test_user' ;
49
49
const repo = 'test_repo' ;
50
50
process . env . GH_TOKEN = 'github_token' ;
@@ -66,6 +66,23 @@ test.serial('Verify package, token and repository access and custom URL', async
66
66
t . deepEqual ( t . context . log . args [ 0 ] , [ 'Verify GitHub authentication (%s)' , 'https://othertesturl.com:9090/prefix' ] ) ;
67
67
} ) ;
68
68
69
+ test . serial ( 'Verify package, token and repository access and custom URL without prefix' , async t => {
70
+ const owner = 'test_user' ;
71
+ const repo = 'test_repo' ;
72
+ process . env . GH_TOKEN = 'github_token' ;
73
+ const githubUrl = 'https://othertesturl.com:9090' ;
74
+ const github = authenticate ( { githubUrl} )
75
+ . get ( `/repos/${ owner } /${ repo } ` )
76
+ . reply ( 200 , { permissions : { push : true } } ) ;
77
+
78
+ await t . notThrows (
79
+ verify ( { githubUrl} , { repositoryUrl : `git@othertesturl.com:${ owner } /${ repo } .git` } , t . context . logger )
80
+ ) ;
81
+
82
+ t . true ( github . isDone ( ) ) ;
83
+ t . deepEqual ( t . context . log . args [ 0 ] , [ 'Verify GitHub authentication (%s)' , 'https://othertesturl.com:9090' ] ) ;
84
+ } ) ;
85
+
69
86
test . serial ( 'Verify package, token and repository with environment variables' , async t => {
70
87
const owner = 'test_user' ;
71
88
const repo = 'test_repo' ;
0 commit comments