forked from jezen/is-thirteen
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test.js
24 lines (17 loc) · 822 Bytes
/
test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
const tap = require('tap');
const isThirteen = require('./');
tap.equal(isThirteen(13), true);
tap.equal(isThirteen('13', true), false);
tap.equal(isThirteen('13', false), true);
tap.equal(isThirteen('thirteen'), true);
tap.equal(isThirteen('Thirteen'), true);
tap.equal(isThirteen('dreizehn'), true);
tap.equal(isThirteen('שלוש עשרה'), true);
tap.equal(isThirteen('Remy Hadley'), true);
tap.equal(isThirteen('https://scontent.cdninstagram.com/hphotos-xtf1/t51.2885-15/s320x320/e35/12237511_444845689040315_1101385461_n.jpg'), true);
tap.equal(isThirteen('http://www.metal-archives.com/images/1/5/3/7/153772.jpg'), false);
tap.equal(isThirteen(1101), true);
tap.equal(isThirteen('1101'), true);
tap.equal(isThirteen("13i"), true);
tap.equal(isThirteen("13i+13"), true);
tap.equal(isThirteen("12i"), false);