-
Notifications
You must be signed in to change notification settings - Fork 693
test: remove pre-condition that snapshot do not exists #37203
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
Conversation
Due to migration that runs on cluster bootstrap, sometimes we may have snapshot after startup. So the pre-condition for this test that a snapshot does not exist might not always satisfy. Since the snapshot at position 0 do not actually have the state changes from StreamProcessor, this test still has value. So we keep the test to cover such cases, but only remove the pre-condition.
3cf09cb
to
c0d0edb
Compare
I will port it to 8.7 and main as well. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No blocker, just wondering if we want to be stricter in case the precondition changes again in the future.
@@ -46,7 +46,6 @@ void update( | |||
state.withNetwork(network).withOldBroker().start(true); | |||
final long processInstanceKey = testCase.setUp(state.client()); | |||
final long key = testCase.runBefore(state); | |||
assertThat(state).hasNoSnapshotAvailable(1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤔 Should we assert it's at position 0? 🤷
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did that initially - 751d68c
But I think we don't need to be that strict. If you want, I can bring those changes back.
I guess this has to be forward ported to 8.7 and 8.8 and main? |
Successfully created backport PR for |
Successfully created backport PR for |
Description
Due to migration that runs on cluster bootstrap, sometimes we may have snapshot after startup. So the pre-condition for this test that a snapshot does not exist might not always satisfy.
Since the snapshot at position 0 do not actually have the state changes from StreamProcessor, this test still has value. So we keep the test to cover such cases, but only remove the pre-condition.
Alternately, we can verify that if the snapshot exists it is at position 0. But I think we don't need to be that strict for this test.
Context: slack thread
Checklist