Skip to content
New issue

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

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

Already on GitHub? # to your account

test: Remove verification test for edge cases of incorrect outcome in flaky tests #1187

Merged
merged 2 commits into from
Oct 2, 2020
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
30 changes: 0 additions & 30 deletions test_runner/src/test/kotlin/ftl/json/SavedMatrixTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import ftl.util.MatrixState.INVALID
import ftl.util.MatrixState.PENDING
import ftl.util.webLink
import org.junit.Assert.assertEquals
import org.junit.Ignore
import org.junit.Test
import org.junit.runner.RunWith

Expand Down Expand Up @@ -236,33 +235,4 @@ class SavedMatrixTest {
savedMatrix.outcome
)
}

@Ignore("Should be used to verify https://github.com/Flank/flank/issues/918 fix")
@Test
fun `savedMatrix should have flaky outcome when at least one test is flaky`() {
val expectedOutcome = "flaky"
val successStepExecution = createStepExecution(1) // success
// https://github.com/Flank/flank/issues/918
// This test covers edge case where summary for both step and execution is null and outcome of
// saved matrix was not changed and is set to success
val malformed = createStepExecution(stepId = -666, executionId = -666) // flaky

// below order in the list matters!
val executions = listOf(
successStepExecution,
successStepExecution,
malformed
)

val testMatrix = testMatrix().apply {
testMatrixId = "123"
state = FINISHED
resultStorage = createResultsStorage()
testExecutions = executions
}

val savedMatrix = createSavedMatrix(testMatrix)

assertEquals(expectedOutcome, savedMatrix.outcome)
}
}