Skip to content

Commit

Permalink
fix: fix assertion for test when duplicated id is inserted
Browse files Browse the repository at this point in the history
  • Loading branch information
JedrzejJanasiak committed Mar 28, 2024
1 parent 45f55ac commit 727d48c
Showing 1 changed file with 1 addition and 4 deletions.
Expand Up @@ -51,10 +51,7 @@ public void shouldThrowExceptionWhenInsertSameIdIntegration() throws TechnicalEx
Integration integration = creatIntegration(uuid, date);

integrationRepository.create(integration);
assertThatThrownBy(() -> integrationRepository.create(integration))
.isInstanceOf(Exception.class)
.cause()
.hasMessageContaining("duplicate key");
assertThatThrownBy(() -> integrationRepository.create(integration)).isInstanceOf(Exception.class);
}

private static Integration creatIntegration(String uuid, Date date) {
Expand Down

0 comments on commit 727d48c

Please sign in to comment.