@@ -17,7 +17,7 @@ func TestGetRawContent(t *testing.T) {
1717 tests := []struct {
1818 name string
1919 pattern mock.EndpointPattern
20- opts * RawContentOpts
20+ opts * ContentOpts
2121 owner , repo , path string
2222 statusCode int
2323 contentType string
@@ -36,7 +36,7 @@ func TestGetRawContent(t *testing.T) {
3636 {
3737 name : "branch fetch success" ,
3838 pattern : GetRawReposContentsByOwnerByRepoByBranchByPath ,
39- opts : & RawContentOpts {Ref : "refs/heads/main" },
39+ opts : & ContentOpts {Ref : "refs/heads/main" },
4040 owner : "octocat" , repo : "hello" , path : "README.md" ,
4141 statusCode : 200 ,
4242 contentType : "text/plain" ,
@@ -45,7 +45,7 @@ func TestGetRawContent(t *testing.T) {
4545 {
4646 name : "tag fetch success" ,
4747 pattern : GetRawReposContentsByOwnerByRepoByTagByPath ,
48- opts : & RawContentOpts {Ref : "refs/tags/v1.0.0" },
48+ opts : & ContentOpts {Ref : "refs/tags/v1.0.0" },
4949 owner : "octocat" , repo : "hello" , path : "README.md" ,
5050 statusCode : 200 ,
5151 contentType : "text/plain" ,
@@ -54,7 +54,7 @@ func TestGetRawContent(t *testing.T) {
5454 {
5555 name : "sha fetch success" ,
5656 pattern : GetRawReposContentsByOwnerByRepoBySHAByPath ,
57- opts : & RawContentOpts {SHA : "abc123" },
57+ opts : & ContentOpts {SHA : "abc123" },
5858 owner : "octocat" , repo : "hello" , path : "README.md" ,
5959 statusCode : 200 ,
6060 contentType : "text/plain" ,
@@ -107,7 +107,7 @@ func TestUrlFromOpts(t *testing.T) {
107107
108108 tests := []struct {
109109 name string
110- opts * RawContentOpts
110+ opts * ContentOpts
111111 owner string
112112 repo string
113113 path string
@@ -121,19 +121,19 @@ func TestUrlFromOpts(t *testing.T) {
121121 },
122122 {
123123 name : "ref branch" ,
124- opts : & RawContentOpts {Ref : "refs/heads/main" },
124+ opts : & ContentOpts {Ref : "refs/heads/main" },
125125 owner : "octocat" , repo : "hello" , path : "README.md" ,
126126 want : "https://raw.example.com/octocat/hello/refs/heads/main/README.md" ,
127127 },
128128 {
129129 name : "ref tag" ,
130- opts : & RawContentOpts {Ref : "refs/tags/v1.0.0" },
130+ opts : & ContentOpts {Ref : "refs/tags/v1.0.0" },
131131 owner : "octocat" , repo : "hello" , path : "README.md" ,
132132 want : "https://raw.example.com/octocat/hello/refs/tags/v1.0.0/README.md" ,
133133 },
134134 {
135135 name : "sha" ,
136- opts : & RawContentOpts {SHA : "abc123" },
136+ opts : & ContentOpts {SHA : "abc123" },
137137 owner : "octocat" , repo : "hello" , path : "README.md" ,
138138 want : "https://raw.example.com/octocat/hello/abc123/README.md" ,
139139 },
0 commit comments