Ignore:
Timestamp:
2014-05-09T04:49:54+02:00 (8 years ago)
Author:
Don-vip
Message:

fixes for unit tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/gui/mappaint/MapCSSWithExtendedTextDirectivesTest.groovy

    r7068 r7081  
    44
    55import org.junit.*
    6 import org.openstreetmap.josm.JOSMFixture;
     6import org.openstreetmap.josm.JOSMFixture
    77import org.openstreetmap.josm.gui.mappaint.LabelCompositionStrategy.DeriveLabelFromNameTagsCompositionStrategy
    88import org.openstreetmap.josm.gui.mappaint.LabelCompositionStrategy.TagLookupCompositionStrategy
    99import org.openstreetmap.josm.gui.mappaint.MapPaintStyles.TagKeyReference
     10
    1011class MapCSSWithExtendedTextDirectivesTest {
    11    
    1212
    1313    @BeforeClass
     
    2020        Cascade c = new Cascade()
    2121        c.put("text", new Keyword("auto"))
    22        
     22
    2323        TextElement te = TextElement.create(c, Color.WHITE, false /* no default annotate */)
    2424        assert te.labelCompositionStrategy != null
    2525        assert te.labelCompositionStrategy instanceof DeriveLabelFromNameTagsCompositionStrategy
    2626    }
    27    
     27
    2828    @Test
    2929    public void createTextElementComposingTextFromTag() {
    3030        Cascade c = new Cascade()
    3131        c.put("text", new TagKeyReference("my_name"))
    32        
     32
    3333        TextElement te = TextElement.create(c, Color.WHITE, false /* no default annotate */)
    3434        assert te.labelCompositionStrategy != null
     
    3636        assert te.labelCompositionStrategy.getDefaultLabelTag() == "my_name"
    3737    }
    38        
     38
    3939    @Test
    4040    public void createNullStrategy() {
    4141        Cascade c = new Cascade()
    42        
     42
    4343        TextElement te = TextElement.create(c, Color.WHITE, false /* no default annotate */)
    44         assert te.labelCompositionStrategy == null
     44        assert te == null
    4545    }
    4646}
    47 
Note: See TracChangeset for help on using the changeset viewer.