Update test.ts
This commit is contained in:
parent
4248929445
commit
6999b8eea1
1 changed files with 5 additions and 3 deletions
|
|
@ -1440,16 +1440,18 @@ test('is.nonEmptyStringAndNotWhitespace', t => {
|
|||
t.false(is.nonEmptyStringAndNotWhitespace(' '));
|
||||
t.true(is.nonEmptyStringAndNotWhitespace('🦄'));
|
||||
|
||||
for (const el of [null, undefined, 5, NaN, {}, []]) {
|
||||
t.false(is.nonEmptyStringAndNotWhitespace(el));
|
||||
for (const value of [null, undefined, 5, NaN, {}, []]) {
|
||||
t.false(is.nonEmptyStringAndNotWhitespace(value));
|
||||
|
||||
t.throws(() => {
|
||||
assert.nonEmptyStringAndNotWhitespace(el);
|
||||
assert.nonEmptyStringAndNotWhitespace(value);
|
||||
});
|
||||
}
|
||||
|
||||
t.throws(() => {
|
||||
assert.nonEmptyStringAndNotWhitespace('');
|
||||
});
|
||||
|
||||
t.notThrows(() => {
|
||||
assert.nonEmptyStringAndNotWhitespace('🦄');
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue