Changeset 15275 in josm for trunk/test
- Timestamp:
- 2019-08-04T21:15:10+02:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/gui/mappaint/mapcss/MapCSSParserTest.java
r15245 r15275 446 446 e = new Environment(way1, new MultiCascade(), Environment.DEFAULT_LAYER, null); 447 447 assertEquals(0, Functions.count_roles(e, "from", "to")); 448 449 /* Check with actual call to mapcss functions */ 450 MapCSSStyleSource source = new MapCSSStyleSource("relation[type=destination_sign] {roles: count_roles(\"from\");}"); 451 source.loadStyleSource(); 452 assertEquals(1, source.rules.size()); 453 e = new Environment(rel1, new MultiCascade(), Environment.DEFAULT_LAYER, null); 454 assertTrue(source.rules.get(0).selector.matches(e)); 455 source.rules.get(0).declaration.execute(e); 456 assertEquals((Integer) 1, e.getCascade(Environment.DEFAULT_LAYER).get("roles", null, Integer.class)); 448 457 } 449 458
Note:
See TracChangeset
for help on using the changeset viewer.