Changeset 11905 in josm for trunk/test


Ignore:
Timestamp:
2017-04-14T21:23:29+02:00 (2 years ago)
Author:
Don-vip
Message:

sonar - squid:S2301 - Public methods should not contain selector arguments

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/gui/layer/LayerManagerTest.java

    r11000 r11905  
    159159    }
    160160
     161    /** the tested layer manager */
    161162    protected LayerManager layerManager;
    162163
     
    397398
    398399    /**
    399      * {@link LayerManager#addLayerChangeListener(LayerChangeListener, boolean)} fires fake add events
     400     * {@link LayerManager#addAndFireLayerChangeListener(LayerChangeListener)} fires fake add events
    400401     */
    401402    @Test
     
    406407        layerManager.addLayer(layer1);
    407408        layerManager.addLayer(layer2);
    408         layerManager.addLayerChangeListener(new LayerChangeListener() {
     409        layerManager.addAndFireLayerChangeListener(new LayerChangeListener() {
    409410            @Override
    410411            public void layerRemoving(LayerRemoveEvent e) {
     
    421422                fired.add(e.getAddedLayer());
    422423            }
    423         }, true);
     424        });
    424425
    425426        assertEquals(Arrays.asList(layer1, layer2), fired);
     
    452453
    453454    /**
    454      * {@link LayerManager#removeLayerChangeListener(LayerChangeListener, boolean)} fires fake remove events
     455     * {@link LayerManager#removeAndFireLayerChangeListener(LayerChangeListener)} fires fake remove events
    455456     */
    456457    @Test
     
    477478            }
    478479        };
    479         layerManager.addLayerChangeListener(listener, false);
    480         layerManager.removeLayerChangeListener(listener, true);
     480        layerManager.addLayerChangeListener(listener);
     481        layerManager.removeAndFireLayerChangeListener(listener);
    481482
    482483        assertEquals(Arrays.asList(layer1, layer2), fired);
Note: See TracChangeset for help on using the changeset viewer.