Ticket #11769: 0001-Changed-test-case-to-test-for-EQ-match-type-instead-.patch

File 0001-Changed-test-case-to-test-for-EQ-match-type-instead-.patch, 1.5 KB (added by michael2402, 10 years ago)
  • test/unit/org/openstreetmap/josm/gui/mappaint/mapcss/MapCSSParserTest.groovy

    From 0e2c05160e45f9963088cc9e39a971a28b2e015e Mon Sep 17 00:00:00 2001
    From: Michael Zangl <michael.zangl@student.kit.edu>
    Date: Mon, 10 Aug 2015 13:41:45 +0200
    Subject: [PATCH] Changed test case to test for EQ match type (instead of
     null).
    
    ---
     .../openstreetmap/josm/gui/mappaint/mapcss/MapCSSParserTest.groovy    | 4 ++--
     1 file changed, 2 insertions(+), 2 deletions(-)
    
    diff --git a/test/unit/org/openstreetmap/josm/gui/mappaint/mapcss/MapCSSParserTest.groovy b/test/unit/org/openstreetmap/josm/gui/mappaint/mapcss/MapCSSParserTest.groovy
    index f9066d5..8a2be4f 100644
    a b class MapCSSParserTest {  
    157157    @Test
    158158    public void testStandardKeyCondition() throws Exception {
    159159        def c1 = (Condition.KeyCondition) getParser("[ highway ]").condition(Condition.Context.PRIMITIVE)
    160         assert c1.matchType == null
     160        assert Condition.KeyMatchType.EQ.equals(c1.matchType)
    161161        assert c1.applies(getEnvironment("highway", "unclassified"))
    162162        assert !c1.applies(getEnvironment("railway", "rail"))
    163163        def c2 = (Condition.KeyCondition) getParser("[\"/slash/\"]").condition(Condition.Context.PRIMITIVE)
    164         assert c2.matchType == null
     164        assert Condition.KeyMatchType.EQ.equals(c2.matchType)
    165165        assert c2.applies(getEnvironment("/slash/", "yes"))
    166166        assert !c2.applies(getEnvironment("\"slash\"", "no"))
    167167    }