Changeset 17275 in josm for trunk/test/unit/org/openstreetmap/josm/gui/conflict/pair/ConflictResolverTest.java
- Timestamp:
- 2020-10-28T20:41:00+01:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/gui/conflict/pair/ConflictResolverTest.java
r12726 r17275 2 2 package org.openstreetmap.josm.gui.conflict.pair; 3 3 4 import static org.junit. Assert.assertFalse;5 import static org.junit. Assert.assertNotNull;4 import static org.junit.jupiter.api.Assertions.assertFalse; 5 import static org.junit.jupiter.api.Assertions.assertThrows; 6 6 7 7 import java.util.NoSuchElementException; 8 8 9 import org.junit. Rule;10 import org.junit. Test;9 import org.junit.jupiter.api.Test; 10 import org.junit.jupiter.api.extension.RegisterExtension; 11 11 import org.openstreetmap.josm.command.SequenceCommand; 12 12 import org.openstreetmap.josm.data.conflict.Conflict; … … 23 23 * Unit tests of {@link ConflictResolver} class. 24 24 */ 25 publicclass ConflictResolverTest {25 class ConflictResolverTest { 26 26 27 27 /** 28 28 * Setup test. 29 29 */ 30 @R ule30 @RegisterExtension 31 31 @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD") 32 32 public JOSMTestRules test = new JOSMTestRules().preferences(); … … 35 35 * Unit test of {@link ConflictResolver#buildResolveCommand} - empty case. 36 36 */ 37 @Test (expected = NoSuchElementException.class)38 publicvoid testBuildResolveCommandEmpty() {39 assert NotNull(new ConflictResolver().buildResolveCommand());37 @Test 38 void testBuildResolveCommandEmpty() { 39 assertThrows(NoSuchElementException.class, () -> new ConflictResolver().buildResolveCommand()); 40 40 } 41 41 … … 44 44 */ 45 45 @Test 46 publicvoid testBuildResolveCommandNode() {46 void testBuildResolveCommandNode() { 47 47 ConflictResolver resolver = new ConflictResolver(); 48 48 Node n1 = new Node(LatLon.SOUTH_POLE); … … 60 60 */ 61 61 @Test 62 publicvoid testBuildResolveCommandWay() {62 void testBuildResolveCommandWay() { 63 63 ConflictResolver resolver = new ConflictResolver(); 64 64 Way w1 = new Way(); … … 76 76 */ 77 77 @Test 78 publicvoid testBuildResolveCommandRelation() {78 void testBuildResolveCommandRelation() { 79 79 ConflictResolver resolver = new ConflictResolver(); 80 80 Relation r1 = new Relation();
Note:
See TracChangeset
for help on using the changeset viewer.