Skip to content
Merged
Show file tree
Hide file tree
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 @@ -14,7 +14,7 @@ spec:
backendRefs:
- name: infra-backend-v1
port: 8080
weight: 80
weight: 9
- name: infra-backend-not-existing
port: 8080
weight: 20
weight: 1
2 changes: 1 addition & 1 deletion test/e2e/tests/weighted_backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ func testMixedValidAndInvalid(t *testing.T, suite *suite.ConformanceTestSuite) {
}
}

if !AlmostEquals(successCount, 40, 5) { // The weight of valid backend is 80%, so the expected success count is 50*80%=40
if !AlmostEquals(successCount, sendRequests*.9, 3) { // The weight of valid backend is 90%
t.Errorf("The actual success count is not within the expected range, success %d", successCount)
}
}