mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-10-28 15:00:11 +00:00
test:
- Added second rebuild test, expected to fail until the fix Ref.: https://github.com/VolmitSoftware/Iris/issues/1251
This commit is contained in:
1 parent
7e73e8f599
commit
38a7e0fdb5
1 file changed
+11
@@ -53,6 +53,12 @@ public class ContinentGeneratorTest {
|
|||||||
assertArrayEquals(CONTINENT_MAP_OF_EXISTING_WORLDS, sampleContinentMapAfterRebuild(baseZoomDimension), 0D);
|
assertArrayEquals(CONTINENT_MAP_OF_EXISTING_WORLDS, sampleContinentMapAfterRebuild(baseZoomDimension), 0D);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ExpectedToFailUntilFixed(SHARED_STYLE_GENERATOR_BUG)
|
||||||
|
@Test
|
||||||
|
public void doesRebuildingTheSameWorldTwiceZoomItsContinentMapOnlyOnce() {
|
||||||
|
assertArrayEquals(CONTINENT_MAP_OF_EXISTING_WORLDS, sampleContinentMapAfterSecondRebuild(baseZoomDimension), 0D);
|
||||||
|
}
|
||||||
|
|
||||||
private double[] sampleContinentMapAtWorldStart(IrisDimension dimension) {
|
private double[] sampleContinentMapAtWorldStart(IrisDimension dimension) {
|
||||||
return sampleContinentMap(dimension, SAMPLE_BLOCKS);
|
return sampleContinentMap(dimension, SAMPLE_BLOCKS);
|
||||||
}
|
}
|
||||||
@@ -66,6 +72,11 @@ public class ContinentGeneratorTest {
|
|||||||
return sampleContinentMapAtWorldStart(dimension);
|
return sampleContinentMapAtWorldStart(dimension);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private double[] sampleContinentMapAfterSecondRebuild(IrisDimension dimension) {
|
||||||
|
sampleContinentMapAtWorldStart(dimension);
|
||||||
|
return sampleContinentMapAfterRebuild(dimension);
|
||||||
|
}
|
||||||
|
|
||||||
private double[] sampleContinentMap(IrisDimension dimension, double[][] blocks) {
|
private double[] sampleContinentMap(IrisDimension dimension, double[][] blocks) {
|
||||||
return sampleAtBlocks(ContinentGenerator.create(dimension, new RNG(WORLD_SEED), packData), blocks);
|
return sampleAtBlocks(ContinentGenerator.create(dimension, new RNG(WORLD_SEED), packData), blocks);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user