From d6cb556c135841d3944e54474e82a62c56fc720f Mon Sep 17 00:00:00 2001 From: phmai Date: Tue, 15 Oct 2024 13:39:52 +0200 Subject: [PATCH] fix tests --- .../lib/view/merge/MergeByStoragePriorityTest.java | 12 ++++++------ .../view/missing/ObligatoryLayersResolverTest.java | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/merge/MergeByStoragePriorityTest.java b/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/merge/MergeByStoragePriorityTest.java index 8e47c7a51..e2471147d 100644 --- a/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/merge/MergeByStoragePriorityTest.java +++ b/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/merge/MergeByStoragePriorityTest.java @@ -39,9 +39,9 @@ void checkPriorityMerge() { final TupleNumber tupleNum = new TupleNumber(new JvmInt64(0), Version.fromDouble(3.0),0); Metadata metadata = mock(Metadata.class); - Tuple tu1 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF1, null, null, null, null); - Tuple tu2 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF2, null, null, null, null); - Tuple tu3 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF3, null, null, null, null); + Tuple tu1 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f1.getId(), metadata.getFlags(), bytesF1, null, null, null, null); + Tuple tu2 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f2.getId(), metadata.getFlags(), bytesF2, null, null, null, null); + Tuple tu3 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f3.getId(), metadata.getFlags(), bytesF3, null, null, null, null); ResultTuple t1 = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tu1); ResultTuple t2 = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tu2); @@ -75,9 +75,9 @@ void checkSamePriorityMerge() { final TupleNumber tupleNum = new TupleNumber(new JvmInt64(0), Version.fromDouble(3.0),0); Metadata metadata = mock(Metadata.class); - Tuple tu1 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF1, null, null, null, null); - Tuple tu2 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF2, null, null, null, null); - Tuple tu3 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesF3, null, null, null, null); + Tuple tu1 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f1.getId(), metadata.getFlags(), bytesF1, null, null, null, null); + Tuple tu2 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f2.getId(), metadata.getFlags(), bytesF2, null, null, null, null); + Tuple tu3 = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, f3.getId(), metadata.getFlags(), bytesF3, null, null, null, null); ResultTuple t1 = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tu1); ResultTuple t2 = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tu2); diff --git a/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/missing/ObligatoryLayersResolverTest.java b/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/missing/ObligatoryLayersResolverTest.java index 5371c1c88..55b39897f 100644 --- a/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/missing/ObligatoryLayersResolverTest.java +++ b/here-naksha-lib-view/src/test/java/com/here/naksha/lib/view/missing/ObligatoryLayersResolverTest.java @@ -34,7 +34,7 @@ void shouldPrepareLayerIdToFetchWhenMissing() { byte[] bytesFeature = PgUtil.encodeFeature(feature, 0, null); final TupleNumber tupleNum = new TupleNumber(new JvmInt64(0), Version.fromDouble(3.0),0); Metadata metadata = mock(Metadata.class); - Tuple tuple = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesFeature, null, null, null, null); + Tuple tuple = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, feature.getId(), metadata.getFlags(), bytesFeature, null, null, null, null); ResultTuple resultTuple = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tuple); List singleRowFeatures = new ArrayList<>(); @@ -59,7 +59,7 @@ void shouldPrepareLayerIdToFetchWhenLayerIsNotObligatory() { byte[] bytesFeature = PgUtil.encodeFeature(feature, 0, null); final TupleNumber tupleNum = new TupleNumber(new JvmInt64(0), Version.fromDouble(3.0),0); Metadata metadata = mock(Metadata.class); - Tuple tuple = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, metadata.getId(), metadata.getFlags(), bytesFeature, null, null, null, null); + Tuple tuple = new Tuple(storage, tupleNum, FetchMode.FETCH_ALL, metadata, feature.getId(), metadata.getFlags(), bytesFeature, null, null, null, null); ResultTuple resultTuple = new ResultTuple(storage, tupleNum, ExecutedOp.READ, tuple); List singleRowFeatures = new ArrayList<>();