diff --git a/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestDebugRequestParser.java b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestDebugRequestParser.java index 853acc196..f04edbd93 100644 --- a/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestDebugRequestParser.java +++ b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestDebugRequestParser.java @@ -155,11 +155,6 @@ public class TestDebugRequestParser { } - @Override - public void addWorkoutPaceData(Long workoutId, List paceList) { - - } - @Override public void sendSetMusic() { diff --git a/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestResponseManager.java b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestResponseManager.java index 61199e27f..8e3d65e65 100644 --- a/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestResponseManager.java +++ b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/huawei/TestResponseManager.java @@ -168,11 +168,6 @@ public class TestResponseManager { } - @Override - public void addWorkoutPaceData(Long workoutId, List paceList) { - - } - @Override public void sendSetMusic() { diff --git a/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/xiaomi/activity/XiaomiActivityParserTest.java b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/xiaomi/activity/XiaomiActivityParserTest.java new file mode 100644 index 000000000..432bcd245 --- /dev/null +++ b/app/src/test/java/nodomain/freeyourgadget/gadgetbridge/service/devices/xiaomi/activity/XiaomiActivityParserTest.java @@ -0,0 +1,22 @@ +package nodomain.freeyourgadget.gadgetbridge.service.devices.xiaomi.activity; + +import org.junit.Ignore; +import org.junit.Test; + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.util.Arrays; + +public class XiaomiActivityParserTest { + @Test + @Ignore("helper test for development, remove this while debugging") + public void localTest() throws IOException { + final byte[] data = Files.readAllBytes(Paths.get("/storage/activity.bin")); + final byte[] fileIdBytes = Arrays.copyOfRange(data, 0, 7); + final XiaomiActivityFileId fileId = XiaomiActivityFileId.from(fileIdBytes); + final XiaomiActivityParser parser = XiaomiActivityParser.create(fileId); + + parser.parse(null, fileId, data); + } +}