Skip to content

Commit 5e66ca1

Browse files
authored
make a few more paths cross platform (#27)
1 parent 27e5058 commit 5e66ca1

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

converter/java/src/test/java/com/mlt/converter/MltConverterTest.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
public class MltConverterTest { ;
2929
private static final String OMT_MVT_PATH = Paths.get("..","..","test","fixtures","omt","mvt").toString();
3030
private static final String BING_MVT_PATH = Paths.get("..","..","test","fixtures","bing","mvt").toString();
31+
private static final String AMZ_HERE_MVT_PATH = Paths.get("..","..","test","fixtures","amazon_here","mvt").toString();
3132

3233
@Test
3334
public void createTileMetadata_Omt_ValidMetadata() throws IOException {
@@ -99,7 +100,7 @@ public void createTileMetadata_Omt_ValidMetadata() throws IOException {
99100

100101
@Test
101102
public void convert_AmazonRandomZLevels_ValidMLtTile() throws IOException {
102-
var tiles = Stream.of(new File("..\\..\\test\\fixtures\\amazon_here\\mvt").listFiles())
103+
var tiles = Stream.of(new File(AMZ_HERE_MVT_PATH).listFiles())
103104
.filter(file -> !file.isDirectory())
104105
.map(File::getAbsoluteFile)
105106
.collect(Collectors.toSet());
@@ -113,7 +114,7 @@ public void convert_AmazonRandomZLevels_ValidMLtTile() throws IOException {
113114

114115
@Test
115116
public void convert_OmtRandomZLevels_ValidMLtTile() throws IOException {
116-
var tiles = Stream.of(new File("..\\..\\test\\fixtures\\omt2").listFiles())
117+
var tiles = Stream.of(new File(OMT_MVT_PATH).listFiles())
117118
.filter(file -> !file.isDirectory())
118119
.map(File::getAbsoluteFile)
119120
.collect(Collectors.toSet());

converter/java/src/test/java/com/mlt/decoder/MltDecoderBenchmark.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import java.util.Optional;
1717

1818
public class MltDecoderBenchmark {
19-
private static final String OMT_MVT_PATH = "..\\..\\test\\fixtures\\omt\\mvt";
19+
private static final String OMT_MVT_PATH = Paths.get("..","..","test","fixtures","omt","mvt").toString();
2020

2121
@Test
2222
public void decodeMlTile_Z4() throws IOException {

converter/java/src/test/java/com/mlt/decoder/MltDecoderTest.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
import static org.junit.jupiter.api.Assertions.assertEquals;
2222

2323
public class MltDecoderTest {
24-
private static final String OMT_MVT_PATH = "..\\..\\test\\fixtures\\omt\\mvt";
24+
private static final String OMT_MVT_PATH = Paths.get("..","..","test","fixtures","omt","mvt").toString();
2525

2626
/** Decode tiles in an in-memory format optimized for sequential access */
2727

converter/java/src/test/java/com/mlt/decoder/StringDecoderTest.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import java.util.Optional;
1919

2020
public class StringDecoderTest {
21-
private static final String OMT_MVT_PATH = "..\\..\\test\\fixtures\\omt\\mvt";
21+
private static final String OMT_MVT_PATH = Paths.get("..","..","test","fixtures","omt","mvt").toString();
2222

2323
@Test
2424
public void decodeSharedDictionary_FsstDictionaryEncoded() throws IOException {

0 commit comments

Comments
 (0)