Ignore:
Timestamp:
2014-08-01T21:05:34+02:00 (10 years ago)
Author:
Don-vip
Message:

see #10206 - update Groovy tests

Location:
trunk/test/unit/org/openstreetmap/josm/data/validation/tests
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/data/validation/tests/LanesTest.groovy

    r7081 r7357  
    11package org.openstreetmap.josm.data.validation.tests
    22
    3 import org.openstreetmap.josm.TestUtils
     3import org.openstreetmap.josm.data.osm.OsmUtils
    44
    55class LanesTest extends GroovyTestCase {
     
    2222
    2323    void test1() {
    24         lanes.check(TestUtils.createPrimitive("way turn:lanes=left|right change:lanes=only_left|not_right|yes"))
     24        lanes.check(OsmUtils.createPrimitive("way turn:lanes=left|right change:lanes=only_left|not_right|yes"))
    2525        assert lanes.errors.get(0).getMessage() == "Number of lane dependent values inconsistent"
    2626    }
    2727
    2828    void test2() {
    29         lanes.check(TestUtils.createPrimitive("way width:lanes:forward=1|2|3 psv:lanes:forward=no|designated"))
     29        lanes.check(OsmUtils.createPrimitive("way width:lanes:forward=1|2|3 psv:lanes:forward=no|designated"))
    3030        assert lanes.errors.get(0).getMessage() == "Number of lane dependent values inconsistent in forward direction"
    3131    }
    3232
    3333    void test3() {
    34         lanes.check(TestUtils.createPrimitive("way change:lanes:forward=yes|no turn:lanes:backward=left|right|left"))
     34        lanes.check(OsmUtils.createPrimitive("way change:lanes:forward=yes|no turn:lanes:backward=left|right|left"))
    3535        assert lanes.errors.isEmpty()
    3636    }
    3737
    3838    void test4() {
    39         lanes.check(TestUtils.createPrimitive("way turn:lanes:forward=left|right change:lanes:forward=yes|no|yes width:backward=1|2|3"))
     39        lanes.check(OsmUtils.createPrimitive("way turn:lanes:forward=left|right change:lanes:forward=yes|no|yes width:backward=1|2|3"))
    4040        assert lanes.errors.get(0).getMessage() == "Number of lane dependent values inconsistent in forward direction"
    4141    }
    4242
    4343    void test5() {
    44         lanes.check(TestUtils.createPrimitive("way lanes:forward=5 turn:lanes:forward=left|right"))
     44        lanes.check(OsmUtils.createPrimitive("way lanes:forward=5 turn:lanes:forward=left|right"))
    4545        assert lanes.errors.get(0).getMessage() == "Number of lanes:forward greater than *:lanes:forward"
    4646    }
    4747
    4848    void test6() {
    49         lanes.check(TestUtils.createPrimitive("way lanes:forward=foo|bar turn:lanes:forward=foo+bar"))
     49        lanes.check(OsmUtils.createPrimitive("way lanes:forward=foo|bar turn:lanes:forward=foo+bar"))
    5050        assert lanes.errors.isEmpty()
    5151    }
    5252
    5353    void test7() {
    54         lanes.check(TestUtils.createPrimitive("way lanes=3 lanes:forward=3 lanes:backward=7"))
     54        lanes.check(OsmUtils.createPrimitive("way lanes=3 lanes:forward=3 lanes:backward=7"))
    5555        assert lanes.errors.get(0).getMessage() == "Number of lanes:forward+lanes:backward greater than lanes"
    5656    }
    5757
    5858    void test8() {
    59         lanes.check(TestUtils.createPrimitive("way destination:country:lanes=X|Y;Z|none destination:ref:lanes=xyz|| destination:sign:lanes=none|airport|none"))
     59        lanes.check(OsmUtils.createPrimitive("way destination:country:lanes=X|Y;Z|none destination:ref:lanes=xyz|| destination:sign:lanes=none|airport|none"))
    6060        assert lanes.errors.isEmpty()
    6161    }
  • trunk/test/unit/org/openstreetmap/josm/data/validation/tests/RelationCheckerTest.groovy

    r7254 r7357  
    11// License: GPL. For details, see LICENSE file.
    22package org.openstreetmap.josm.data.validation.tests
     3
     4import static org.openstreetmap.josm.data.osm.OsmUtils.createPrimitive
    35
    46import org.openstreetmap.josm.JOSMFixture
     
    810import org.openstreetmap.josm.data.validation.TestError
    911import org.openstreetmap.josm.gui.tagging.TaggingPresets
    10 
    11 import static org.openstreetmap.josm.TestUtils.createPrimitive
    1212
    1313class RelationCheckerTest extends GroovyTestCase {
Note: See TracChangeset for help on using the changeset viewer.