File tree Expand file tree Collapse file tree 2 files changed +2
-24
lines changed Expand file tree Collapse file tree 2 files changed +2
-24
lines changed Original file line number Diff line number Diff line change @@ -153,19 +153,17 @@ spec:
153153 ResourceApplied ("HTTPRoute" , "httpbin" , exactRouteByGet , 1 )
154154
155155 By ("access dataplane to check the HTTPRoute" )
156- // time.Sleep(1000000 * time.Second)
157- s .NewAPISIXClientWithHTTPS ().
156+ s .NewAPISIXHttpsClient ("api6.com" ).
158157 GET ("/get" ).
159158 WithHost ("api6.com" ).
160159 Expect ().
161160 Status (200 )
162- // time.Sleep(1000 * time.Second)
163161 By ("delete HTTPRoute" )
164162 err := s .DeleteResourceFromString (exactRouteByGet )
165163 Expect (err ).NotTo (HaveOccurred (), "deleting HTTPRoute" )
166164 time .Sleep (5 * time .Second )
167165
168- s .NewAPISIXClientWithHTTPS ( ).
166+ s .NewAPISIXHttpsClient ( "api6.com" ).
169167 GET ("/get" ).
170168 WithHost ("api6.com" ).
171169 Expect ().
Original file line number Diff line number Diff line change @@ -214,26 +214,6 @@ func (s *Scaffold) NewAPISIXClient() *httpexpect.Expect {
214214 })
215215}
216216
217- // NewAPISIXClient creates the default HTTP client.
218- func (s * Scaffold ) NewAPISIXClientWithHTTPS () * httpexpect.Expect {
219- u := url.URL {
220- Scheme : "https" ,
221- Host : s .apisixHttpsTunnel .Endpoint (),
222- }
223- return httpexpect .WithConfig (httpexpect.Config {
224- BaseURL : u .String (),
225- Client : & http.Client {
226- Transport : & http.Transport {},
227- CheckRedirect : func (req * http.Request , via []* http.Request ) error {
228- return http .ErrUseLastResponse
229- },
230- },
231- Reporter : httpexpect .NewAssertReporter (
232- httpexpect .NewAssertReporter (GinkgoT ()),
233- ),
234- })
235- }
236-
237217// GetAPISIXHTTPSEndpoint get apisix https endpoint from tunnel map
238218func (s * Scaffold ) GetAPISIXHTTPSEndpoint () string {
239219 return s .apisixHttpsTunnel .Endpoint ()
You can’t perform that action at this time.
0 commit comments