Skip to content

Commit

Permalink
[Tests]: extend string '_' test to include numeric
Browse files Browse the repository at this point in the history
  • Loading branch information
shadowspawn committed Nov 25, 2023
1 parent 591d1bb commit 2e7c498
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/parse.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,14 @@ test('strings', function (t) {
});

test('stringArgs', function (t) {
var s = parse([' ', ' '], { string: '_' })._;
t.same(s.length, 2);
var s = parse([' ', ' ', '3'], { string: '_' })._;
t.same(s.length, 3);
t.same(typeof s[0], 'string');
t.same(s[0], ' ');
t.same(typeof s[1], 'string');
t.same(s[1], ' ');
t.same(typeof s[2], 'string');
t.same(s[2], '3');
t.end();
});

Expand Down

0 comments on commit 2e7c498

Please sign in to comment.