@@ -30,11 +30,11 @@ func TestNew(t *testing.T) {
30
30
}, {
31
31
description : "different github url" ,
32
32
ghUrl : "https://example.com" ,
33
- opts : []Option {WithURL ("https://example.com" )},
33
+ opts : []Option {WithGithubURL ("https://example.com" )},
34
34
}, {
35
35
description : "different http url" ,
36
36
rawUrl : "https://example.com" ,
37
- opts : []Option {WithRawURL ("https://example.com" )},
37
+ opts : []Option {WithRawDownloadURL ("https://example.com" )},
38
38
}, {
39
39
description : "different http client" ,
40
40
nilHttpClient : true ,
@@ -45,8 +45,8 @@ func TestNew(t *testing.T) {
45
45
opts : []Option {WithThresholdInKB (10 )},
46
46
}, {
47
47
description : "specify orgs and repos." ,
48
- opts : []Option {WithFullOrg ("foo" ),
49
- WithFullOrg ("bar" , true ),
48
+ opts : []Option {WithOrg ("foo" ),
49
+ WithOrg ("bar" , true ),
50
50
WithRepo ("org" , "repo" ),
51
51
WithRepo ("cat" , "repo" , "branch1" , "branch2" ),
52
52
},
@@ -149,22 +149,22 @@ func TestMostThings(t *testing.T) {
149
149
expectErr : true ,
150
150
}, {
151
151
description : "fetch a few of repos test" ,
152
- opts : []Option {WithFullOrg ("org" )},
152
+ opts : []Option {WithOrg ("org" )},
153
153
payload : []string {twoReposResponse },
154
154
expect : []string {"org/.github/git" , "org/.go-template/git" },
155
155
}, {
156
156
description : "fetch a few of repos spread across requests test" ,
157
- opts : []Option {WithFullOrg ("org" )},
157
+ opts : []Option {WithOrg ("org" )},
158
158
payload : []string {twoReposOneAtATimeResponse001 , twoReposOneAtATimeResponse002 },
159
159
expect : []string {"org/.github/git" , "org/.go-template/git" },
160
160
}, {
161
161
description : "fetch a disabled and archived repo." ,
162
- opts : []Option {WithFullOrg ("org" )},
162
+ opts : []Option {WithOrg ("org" )},
163
163
payload : []string {twoReposOneDisabledResponse },
164
164
unexpected : []string {"org/.github/git" , "org/.go-template/git" },
165
165
}, {
166
166
description : "get an invalid response during fetching a single repo" ,
167
- opts : []Option {WithFullOrg ("org" )},
167
+ opts : []Option {WithOrg ("org" )},
168
168
payload : []string {invalidJsonResponse },
169
169
expect : []string {"org/repo/git" , "org/moved/git" },
170
170
expectErr : true ,
@@ -292,7 +292,7 @@ func TestMostThings(t *testing.T) {
292
292
293
293
server .Start ()
294
294
295
- tc .opts = append (tc .opts , WithURL (server .URL ), WithRawURL (server .URL ))
295
+ tc .opts = append (tc .opts , WithGithubURL (server .URL ), WithRawDownloadURL (server .URL ))
296
296
gfs := New (tc .opts ... )
297
297
require .NotNil (gfs )
298
298
0 commit comments