Skip to content

Commit

Permalink
Don't rely on db ids for testing.
Browse files Browse the repository at this point in the history
  • Loading branch information
meistermeier committed Aug 24, 2023
1 parent edb49b7 commit c5fa066
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,13 @@ public void shouldCorrectlyMapNodesAndRelsWithSameId() {
Collections.emptyMap());

// verify that we reached the expected setup
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0001'}) RETURN id(n)", Collections.emptyMap())).isEqualTo(0L);
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0002'}) RETURN id(n)", Collections.emptyMap())).isEqualTo(1L);
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0003'}) RETURN id(n)", Collections.emptyMap())).isEqualTo(2L);
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0001'}) RETURN id(n)", Collections.emptyMap())).isNotNull();
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0002'}) RETURN id(n)", Collections.emptyMap())).isNotNull();
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH (n{uuid:'AAAA0003'}) RETURN id(n)", Collections.emptyMap())).isNotNull();
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH ()-[r{uuid:'BBBB0001'}]->() RETURN id(r)", Collections.emptyMap()))
.isEqualTo(0L);
.isNotNull();
BDDAssertions.assertThat(session.queryForObject(Long.class, "MATCH ()-[r{uuid:'BBBB0002'}]->() RETURN id(r)", Collections.emptyMap()))
.isEqualTo(1L);
.isNotNull();

// load the relationship entity between Moby-Dick and Jane Doe including the children of Jane
BDDAssertions.assertThat(//
Expand Down

0 comments on commit c5fa066

Please sign in to comment.