Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: clean up resources after test run #296

Merged
merged 1 commit into from
Jul 13, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ import (
)

var _ = Describe("Test 2 listeners gateway with weighted httproute rules and service export import", func() {
// Clean up resources in case an assertion failed before cleaning up
// at the end
AfterEach(func() {
testFramework.CleanTestEnvironment(ctx)
})

It("Create a gateway with 2 listeners(http and https), create a weightedRoutingHttpRoute that parentRef to both http and https listeners,"+
" and this httpRoute BackendRef to one service and one serviceImport, weighted traffic should work for both http and https listeners",
func() {
Expand Down Expand Up @@ -134,7 +140,7 @@ var _ = Describe("Test 2 listeners gateway with weighted httproute rules and ser
} else if strings.Contains(stdout, "service-import-export-test1 handler pod") {
hitTg1++
} else {
Fail("Unexpected response")
Fail(fmt.Sprintf("Unexpected response: %s", stdout))
}
}
log.Printf("Send traffic to %s listener: \n", protocol)
Expand Down