File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -20,8 +20,7 @@ test-kubo-subdomains: provision-kubo gateway-conformance
2020 " Paths" : [" /ipfs" , " /ipns" , " /api" ] \
2121 } \
2222 }'
23- # todo: SUBDOMAIN_GATEWAY_URL should be a cmd parameter
24- ./gateway-conformance test --json output.json --gateway-url ${GATEWAY_URL} --subdomain-url ${SUBDOMAIN_GATEWAY_URL} --specs +subdomain-gateway
23+ ./gateway-conformance test --json output.json --gateway-url http://127.0.0.1:8080 --subdomain-url http://example.com:8080 --specs +subdomain-gateway
2524
2625test-kubo : provision-kubo
2726 GATEWAY_URL=http://127.0.0.1:8080 make _test
Original file line number Diff line number Diff line change @@ -57,6 +57,7 @@ func copyFiles(inputPaths []string, outputDirectoryPath string) error {
5757
5858func main () {
5959 var gatewayURL string
60+ var subdomainGatewayURL string
6061 var jsonOutput string
6162 var specs string
6263 var directory string
@@ -78,6 +79,12 @@ func main() {
7879 Value : "http://localhost:8080" ,
7980 Destination : & gatewayURL ,
8081 },
82+ & cli.StringFlag {
83+ Name : "subdomain-url" ,
84+ Usage : "The Subdomain URL of the IPFS Gateway implementation to be tested." ,
85+ Value : "http://example.com:8080" ,
86+ Destination : & subdomainGatewayURL ,
87+ },
8188 & cli.StringFlag {
8289 Name : "json-output" ,
8390 Aliases : []string {"json" , "j" },
@@ -107,6 +114,11 @@ func main() {
107114 cmd := exec .Command ("go" , args ... )
108115 cmd .Dir = tooling .Home ()
109116 cmd .Env = append (os .Environ (), fmt .Sprintf ("GATEWAY_URL=%s" , gatewayURL ))
117+
118+ if subdomainGatewayURL != "" {
119+ cmd .Env = append (cmd .Env , fmt .Sprintf ("SUBDOMAIN_GATEWAY_URL=%s" , subdomainGatewayURL ))
120+ }
121+
110122 cmd .Stdout = out {output }
111123 cmd .Stderr = os .Stderr
112124 testErr := cmd .Run ()
You can’t perform that action at this time.
0 commit comments