fleetmap-reports 1.0.496 → 1.0.498

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "fleetmap-reports",
3
- "version": "1.0.496",
3
+ "version": "1.0.498",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
7
- "test": "jest"
7
+ "test": "email=$email & password=$password & jest"
8
8
  },
9
9
  "keywords": [],
10
10
  "author": "",
package/src/index.test.js CHANGED
@@ -22,7 +22,7 @@ describe('Test_Reports', function () {
22
22
  userData.roadSpeedLimits = true
23
23
  const { device, totalDistance, totalEventTime } = await getSpeedingReport(report, userData)
24
24
  assert.equal(device.alerts.length, 104) // Total Alerts
25
- assert.equal(totalDistance, 36.6525856031222) // Total Kms
25
+ assert.equal(totalDistance, 36.63687856826021) // Total Kms
26
26
  assert.equal(totalEventTime, 1524000) // Total Duration
27
27
  }, 200000)
28
28
  // eslint-disable-next-line no-undef
@@ -315,7 +315,6 @@ async function getHereEvents (devices, routes, threshold) {
315
315
  timestamps[new Date(p.fixTime).getTime()] = p
316
316
  }
317
317
  const reduced = results.reduce((acc, cur, idx, src) => {
318
- console.log('idx', idx)
319
318
  cur.overSpeeding = cur.currentSpeedKmh > parseInt(cur.speedLimit) + (threshold || 0)
320
319
  const last = acc.length && acc.slice(-1)[0]
321
320
  cur.position = timestamps[cur.timestamp]