MCPcopy Create free account
hub / github.com/Neop/mudmap2 / testGetLayers

Method testGetLayers

src/test/java/mudmap2/backend/WorldTest.java:378–399  ·  view source on GitHub ↗

Test of getLayers method, of class World.

()

Source from the content-addressed store, hash-verified

376 * Test of getLayers method, of class World.
377 */
378 @Test
379 public void testGetLayers() {
380 System.out.println("getLayers");
381
382 World instance = new World("MyWorld");
383
384 Collection<Layer> layers = instance.getLayers();
385 assertNotNull(layers);
386 assertTrue(layers.isEmpty());
387
388 Layer l1 = new Layer(instance);
389 instance.addLayer(l1);
390 Layer l2 = new Layer(instance);
391 instance.addLayer(l2);
392 Layer l3 = instance.getNewLayer();
393
394 layers = instance.getLayers();
395 assertEquals(3, layers.size());
396 assertTrue(layers.contains(l1));
397 assertTrue(layers.contains(l2));
398 assertTrue(layers.contains(l3));
399 }
400
401 /**
402 * Test of getPathColorStd method, of class World.

Callers

nothing calls this directly

Calls 5

getLayersMethod · 0.95
addLayerMethod · 0.95
getNewLayerMethod · 0.95
isEmptyMethod · 0.65
containsMethod · 0.65

Tested by

no test coverage detected