mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-12-28 11:35:48 +01:00
Fix unit tests
This commit is contained in:
parent
f3b4f0ed26
commit
8714c8461f
@ -155,11 +155,6 @@ public class TestDebugRequestParser {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addWorkoutPaceData(Long workoutId, List<Workout.WorkoutPace.Response.Block> paceList) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void sendSetMusic() {
|
||||
|
||||
|
@ -168,11 +168,6 @@ public class TestResponseManager {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addWorkoutPaceData(Long workoutId, List<Workout.WorkoutPace.Response.Block> paceList) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void sendSetMusic() {
|
||||
|
||||
|
@ -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);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user