mirror of
https://github.com/datahub-project/datahub.git
synced 2025-12-13 11:06:30 +00:00
fix(test): fix test specific for single query (#11567)
This commit is contained in:
parent
ef4805d852
commit
f09e18cdb8
@ -56,7 +56,8 @@ public class EbeanAspectDaoTest {
|
|||||||
|
|
||||||
testDao.runInTransactionWithRetryUnlocked(
|
testDao.runInTransactionWithRetryUnlocked(
|
||||||
(txContext) -> {
|
(txContext) -> {
|
||||||
testDao.getLatestAspects(Map.of("urn:li:corpuser:test", Set.of("status")), true);
|
testDao.getLatestAspects(
|
||||||
|
Map.of("urn:li:corpuser:testGetLatestAspectsForUpdate", Set.of("status")), true);
|
||||||
return "";
|
return "";
|
||||||
},
|
},
|
||||||
mock(AspectsBatch.class),
|
mock(AspectsBatch.class),
|
||||||
@ -65,7 +66,7 @@ public class EbeanAspectDaoTest {
|
|||||||
// Get the captured SQL statements
|
// Get the captured SQL statements
|
||||||
List<String> sql =
|
List<String> sql =
|
||||||
LoggedSql.stop().stream()
|
LoggedSql.stop().stream()
|
||||||
.filter(str -> str.contains("(t0.urn,t0.aspect,t0.version)"))
|
.filter(str -> str.contains("testGetLatestAspectsForUpdate"))
|
||||||
.toList();
|
.toList();
|
||||||
assertEquals(
|
assertEquals(
|
||||||
sql.size(), 1, String.format("Found: %s", new ObjectMapper().writeValueAsString(sql)));
|
sql.size(), 1, String.format("Found: %s", new ObjectMapper().writeValueAsString(sql)));
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user