forked from orbit-oss/is
Add failing test for #174
This commit is contained in:
parent
911f44dc36
commit
f3693674f6
1 changed files with 11 additions and 0 deletions
11
test/test.ts
11
test/test.ts
|
|
@ -1435,6 +1435,17 @@ test('is.nonEmptyArray', t => {
|
|||
t.throws(() => {
|
||||
assert.nonEmptyArray(new Array()); // eslint-disable-line @typescript-eslint/no-array-constructor
|
||||
});
|
||||
|
||||
// https://github.com/sindresorhus/is/issues/174
|
||||
// {
|
||||
// const strings = ['foo', 'bar']
|
||||
// const function_ = (value: string) => value;
|
||||
|
||||
// if (is.nonEmptyArray(strings)) {
|
||||
// const value = strings[0]
|
||||
// function_(value);
|
||||
// }
|
||||
// }
|
||||
});
|
||||
|
||||
test('is.emptyString', t => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue