Ignore:
Timestamp:
2018-08-11T17:29:48+02:00 (6 years ago)
Author:
Don-vip
Message:

see #15229 - deprecate all Main methods related to projections. New ProjectionRegistry class

Location:
trunk/test/unit/org/openstreetmap/josm/data/osm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/data/osm/DataSetMergerTest.java

    r12750 r14120  
    1919import org.junit.Rule;
    2020import org.junit.Test;
    21 import org.openstreetmap.josm.Main;
    2221import org.openstreetmap.josm.data.coor.LatLon;
     22import org.openstreetmap.josm.data.projection.ProjectionRegistry;
    2323import org.openstreetmap.josm.data.projection.Projections;
    2424import org.openstreetmap.josm.testutils.JOSMTestRules;
     
    4949        their = new DataSet();
    5050        their.setVersion("0.6");
    51         Main.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
     51        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
    5252    }
    5353
  • trunk/test/unit/org/openstreetmap/josm/data/osm/OsmPrimitiveTest.java

    r10945 r14120  
    99import org.junit.Rule;
    1010import org.junit.Test;
    11 import org.openstreetmap.josm.Main;
    1211import org.openstreetmap.josm.data.coor.LatLon;
     12import org.openstreetmap.josm.data.projection.ProjectionRegistry;
    1313import org.openstreetmap.josm.data.projection.Projections;
    1414import org.openstreetmap.josm.testutils.JOSMTestRules;
     
    4040    @BeforeClass
    4141    public static void setUp() {
    42         Main.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
     42        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
    4343    }
    4444
  • trunk/test/unit/org/openstreetmap/josm/data/osm/QuadBucketsTest.java

    r14092 r14120  
    1717import org.junit.Rule;
    1818import org.junit.Test;
    19 import org.openstreetmap.josm.Main;
    2019import org.openstreetmap.josm.data.coor.LatLon;
     20import org.openstreetmap.josm.data.projection.ProjectionRegistry;
    2121import org.openstreetmap.josm.data.projection.Projections;
    2222import org.openstreetmap.josm.gui.progress.NullProgressMonitor;
     
    8383    @Test
    8484    public void testRemove() throws Exception {
    85         Main.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
     85        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
    8686        try (InputStream fis = new FileInputStream("data_nodist/restriction.osm")) {
    8787            DataSet ds = OsmReader.parseDataSet(fis, NullProgressMonitor.INSTANCE);
     
    9696    @Test
    9797    public void testMove() throws Exception {
    98         Main.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
     98        ProjectionRegistry.setProjection(Projections.getProjectionByCode("EPSG:3857")); // Mercator
    9999        try (InputStream fis = new FileInputStream("data_nodist/restriction.osm")) {
    100100            DataSet ds = OsmReader.parseDataSet(fis, NullProgressMonitor.INSTANCE);
Note: See TracChangeset for help on using the changeset viewer.