Skip to content

Commit

Permalink
test: Harden DynamoDBTimestampOffsetProjectionSpec (#1264)
Browse files Browse the repository at this point in the history
* failing test: "store offset for failing events when using RecoveryStrategy.skip"
* projection might have been stopped before the error occured
  • Loading branch information
patriknw authored Nov 22, 2024
1 parent 1751e82 commit d5433ff
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -921,6 +921,7 @@ class DynamoDBTimestampOffsetProjectionSpec
offsetShouldBeEmpty()
projectionTestKit.run(projectionFailing) {
projectedTestValueShouldBe("e1|e2|e3|e4|e5")
bogusEventHandler.attempts shouldBe 1
}
eventually {
latestOffsetShouldBe(envelopes.last.offset)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,7 @@ class JdbcProjectionSpec
offsetShouldBeEmpty()
projectionTestKit.run(projectionFailing) {
projectedValueShouldBe("e1|e2|e3|e4|e5")
bogusEventHandler.attempts shouldBe 1
}
eventually {
offsetShouldBe(6L)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,7 @@ class R2dbcProjectionSpec
offsetShouldBeEmpty()
projectionTestKit.run(projectionFailing) {
projectedValueShouldBe("e1|e2|e3|e4|e5")
bogusEventHandler.attempts shouldBe 1
}
eventually {
offsetShouldBe(6L)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,7 @@ class R2dbcTimestampOffsetProjectionSpec
offsetShouldBeEmpty()
projectionTestKit.run(projectionFailing) {
projectedValueShouldBe("e1|e2|e3|e4|e5")
bogusEventHandler.attempts shouldBe 1
}
eventually {
offsetShouldBe(envelopes.last.offset)
Expand Down

0 comments on commit d5433ff

Please sign in to comment.