Changeset 11302 in josm for trunk/test


Ignore:
Timestamp:
2016-11-23T23:39:53+01:00 (3 years ago)
Author:
simon04
Message:

OsmUrlToBounds: Make getZoom return the previously parsed zoom level

Might be a regression of r4706.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/tools/OsmUrlToBoundsTest.java

    r11299 r11302  
    100100        }
    101101    }
     102
     103    /**
     104     * Test for {@link OsmUrlToBounds#getZoom}.
     105     */
     106    @Test
     107    public void testGetZoom() {
     108        Assert.assertEquals(4, OsmUrlToBounds.getZoom(OsmUrlToBounds.positionToBounds(0, 0, 4)));
     109        Assert.assertEquals(10, OsmUrlToBounds.getZoom(OsmUrlToBounds.positionToBounds(5, 5, 10)));
     110        Assert.assertEquals(18, OsmUrlToBounds.getZoom(OsmUrlToBounds.positionToBounds(40, 20, 18)));
     111    }
    102112}
Note: See TracChangeset for help on using the changeset viewer.