Skip to content

Commit

Permalink
Generalize the timezone to check
Browse files Browse the repository at this point in the history
  • Loading branch information
d3x0r committed May 18, 2024
1 parent 4d08da8 commit 3d42f56
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/1.2.113-DateNS.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
const JSOX = require( "../lib/jsox.js" );

describe('Added in 1.2.113 (DateNS)', function () {
const t = JSOX.DateNS("2022-01-01T00:00:00Z").toISOString();
const t = JSOX.stringify( new JSOX.DateNS("2022-01-01T00:00:00Z"));
const plus = t.lastIndexOf( "+" );
const minus = t.lastIndexOf( "-" );
const Z = t.lastINdexOf( "Z" );
const Z = t.lastIndexOf( "Z" );
const pos = ( plus > minus )?(plus>Z)?plus:Z:(minus>Z)?minus:Z;
const tz = t.substr( pos );
it( 'handles stringify', function() {
Expand Down

0 comments on commit 3d42f56

Please sign in to comment.