Last change
on this file since 11241 was 11008, checked in by Don-vip, 8 years ago |
fix #13646 - NPE + unit test
|
-
Property svn:eol-style
set to
native
|
File size:
557 bytes
|
Line | |
---|
1 | // License: GPL. For details, see LICENSE file.
|
---|
2 | package org.openstreetmap.josm.gui.layer;
|
---|
3 |
|
---|
4 | import static org.junit.Assert.assertEquals;
|
---|
5 |
|
---|
6 | import org.junit.Test;
|
---|
7 |
|
---|
8 | /**
|
---|
9 | * Test the {@link LayerPositionStrategy} class.
|
---|
10 | */
|
---|
11 | public class LayerPositionStrategyTest {
|
---|
12 |
|
---|
13 | /**
|
---|
14 | * Test of robustness against null manager.
|
---|
15 | */
|
---|
16 | @Test
|
---|
17 | public void testNullManager() {
|
---|
18 | assertEquals(0, LayerPositionStrategy.inFrontOfFirst(l -> true).getPosition(null));
|
---|
19 | assertEquals(0, LayerPositionStrategy.afterLast(l -> true).getPosition(null));
|
---|
20 | }
|
---|
21 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.