UNPKG

@jbroll/nmea-simple

Version:

NMEA 0183 sentence parser and encoder

15 lines (14 loc) 597 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); require("should"); var helpers_1 = require("../helpers"); describe("Parse", function () { it("Coordinate", function () { helpers_1.parseDmCoordinate("0").should.equal(0); helpers_1.parseDmCoordinate("0.0").should.equal(0); helpers_1.parseDmCoordinate("30.00").should.equal(0.5); helpers_1.parseDmCoordinate("130.00").should.equal(1.5); helpers_1.parseDmCoordinate("1030.00").should.equal(10.5); helpers_1.parseDmCoordinate("10030.00").should.equal(100.5); }); });