diff --git a/src/test/java/osm/jp/gpx/Expecter.java b/src/test/java/osm/jp/gpx/Expecter.java new file mode 100644 index 0000000..f7dfb1b --- /dev/null +++ b/src/test/java/osm/jp/gpx/Expecter.java @@ -0,0 +1,20 @@ +package osm.jp.gpx; + +public class Expecter { + String value; + boolean expect; + String timeStr; + double latD; + double lonD; + boolean magvar; + + public Expecter(String value, boolean expect, String timeStr, double latD, double lonD, boolean magvar) { + this.value = value; + this.expect = expect; + this.timeStr = timeStr; + this.latD = latD; + this.lonD = lonD; + this.magvar = magvar; + } + +} diff --git a/src/test/java/osm/jp/gpx/Fixture.java b/src/test/java/osm/jp/gpx/Fixture.java new file mode 100644 index 0000000..07fcc7a --- /dev/null +++ b/src/test/java/osm/jp/gpx/Fixture.java @@ -0,0 +1,39 @@ +package osm.jp.gpx; + +import osm.jp.gpx.Expecter; + +public class Fixture { + String comment; // テスト概要(コメント) + String tarFilePath; // TARデータ + String gpxSourcePath; // GPXファイル(オリジナル) + String gpxDestinationPath; // GPXファイル(配置先) + String iniFilePath; // iniファイル + Expecter[] expecters; + + public Fixture( + String comment, + String tarFilePath, + String gpxSourcePath, + String gpxDestinationPath, + String iniFilePath, + Expecter[] expecters + ) { + this.comment = comment; + this.tarFilePath = tarFilePath; + this.gpxSourcePath = gpxSourcePath; + this.gpxDestinationPath = gpxDestinationPath; + this.iniFilePath = iniFilePath; + this.expecters = expecters; + } + + @Override + public String toString() { + String msg = "テストパターン : "+ comment + "\n"; + msg += "\ttarFilePath = "+ tarFilePath +"\n"; + msg += "\tgpxSourcePath = "+ gpxSourcePath +"\n"; + msg += "\tgpxDestinationPath = "+ gpxDestinationPath +"\n"; + msg += "\tiniFilePath = "+ iniFilePath; + return msg; + } + +} diff --git a/src/test/java/osm/jp/gpx/ImportPictureTest.java b/src/test/java/osm/jp/gpx/ImportPictureTest.java index dd856dd..3438d87 100644 --- a/src/test/java/osm/jp/gpx/ImportPictureTest.java +++ b/src/test/java/osm/jp/gpx/ImportPictureTest.java @@ -21,59 +21,6 @@ import org.junit.experimental.theories.Theory; public class ImportPictureTest { - static class Expecter { - String value; - boolean expect; - String timeStr; - double latD; - double lonD; - boolean magvar; - - public Expecter(String value, boolean expect, String timeStr, double latD, double lonD, boolean magvar) { - this.value = value; - this.expect = expect; - this.timeStr = timeStr; - this.latD = latD; - this.lonD = lonD; - this.magvar = magvar; - } - } - - static class Fixture { - String comment; // テスト概要(コメント) - String tarFilePath; // TARデータ - String gpxSourcePath; // GPXファイル(オリジナル) - String gpxDestinationPath; // GPXファイル(配置先) - String iniFilePath; // iniファイル - Expecter[] expecters; - - public Fixture( - String comment, - String tarFilePath, - String gpxSourcePath, - String gpxDestinationPath, - String iniFilePath, - Expecter[] expecters - ) { - this.comment = comment; - this.tarFilePath = tarFilePath; - this.gpxSourcePath = gpxSourcePath; - this.gpxDestinationPath = gpxDestinationPath; - this.iniFilePath = iniFilePath; - this.expecters = expecters; - } - - @Override - public String toString() { - String msg = "テストパターン : "+ comment + "\n"; - msg += "\ttarFilePath = "+ tarFilePath +"\n"; - msg += "\tgpxSourcePath = "+ gpxSourcePath +"\n"; - msg += "\tgpxDestinationPath = "+ gpxDestinationPath +"\n"; - msg += "\tiniFilePath = "+ iniFilePath; - return msg; - } - } - @RunWith(Theories.class) public static class 各種カメラGPXファイル {