aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2017-06-21 00:16:43 +1200
committerGitHub <noreply@github.com>2017-06-21 00:16:43 +1200
commitc79fa263cca2c641775cebb24858f38aa9400a50 (patch)
tree93d4cd495a2eb8248bd4ca0759ead2c30241d55b /test
parent87d3a5d2a2782f57c3dfa50de64052697ca9250d (diff)
parentbc0c4319245de8e4ff62f005b22fc73350090d9e (diff)
downloadtrackermap-server-c79fa263cca2c641775cebb24858f38aa9400a50.tar.gz
trackermap-server-c79fa263cca2c641775cebb24858f38aa9400a50.tar.bz2
trackermap-server-c79fa263cca2c641775cebb24858f38aa9400a50.zip
Merge pull request #3272 from Abyss777/spentFuel_type
Change type of 'spentFuel' to double
Diffstat (limited to 'test')
-rw-r--r--test/org/traccar/reports/ReportUtilsTest.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/org/traccar/reports/ReportUtilsTest.java b/test/org/traccar/reports/ReportUtilsTest.java
index 2fe05e688..adcdf5875 100644
--- a/test/org/traccar/reports/ReportUtilsTest.java
+++ b/test/org/traccar/reports/ReportUtilsTest.java
@@ -60,10 +60,10 @@ public class ReportUtilsTest extends BaseTest {
public void testCalculateSpentFuel() {
Position startPosition = new Position();
Position endPosition = new Position();
- Assert.assertNull(ReportUtils.calculateFuel(startPosition, endPosition));
+ Assert.assertEquals(ReportUtils.calculateFuel(startPosition, endPosition), 0.0, 0.01);
startPosition.set(Position.KEY_FUEL_LEVEL, 0.7);
endPosition.set(Position.KEY_FUEL_LEVEL, 0.5);
- Assert.assertEquals(ReportUtils.calculateFuel(startPosition, endPosition), "0.2");
+ Assert.assertEquals(ReportUtils.calculateFuel(startPosition, endPosition), 0.2, 0.01);
}
@Test