@@ -3,58 +3,8 @@ import { guardFunction } from '../lib/guard-function.func';
33// Variables.
44import { FUNCTION } from '../../is/test/variables/function.const' ;
55
6- describe ( ' guardFunction' , ( ) => {
6+ describe ( guardFunction . name , ( ) => {
77 // TRUE
8- it ( 'is DEFINED' , ( ) => {
9- expect ( guardFunction ) . toBeDefined ( ) ;
10- } ) ;
11- it ( `'function' | Function` , ( ) => {
12- expect ( guardFunction ( FUNCTION ) ) . toBeTruthy ( ) ;
13- } ) ;
14-
15- // FALSE.
16- // it(`Class`, () => {
17- // expect(guardFunction(Class)).toBeTruthy();
18- // });
19- // it(`'boolean' | Boolean`, () => {
20- // expect(guardFunction(FALSE)).toBeFalsy();
21- // expect(guardFunction(TRUE)).toBeFalsy();
22- // expect(guardFunction(FALSE_INSTANCE)).toBeFalsy();
23- // expect(guardFunction(TRUE_INSTANCE)).toBeFalsy();
24- // expect(guardFunction(Boolean(false))).toBeFalsy();
25- // expect(guardFunction(Boolean(true))).toBeFalsy();
26- // });
27- // it(`'bigint'`, () => {
28- // expect(guardFunction(BIGINT)).toBeFalsy();
29- // expect(guardFunction(BIGINT_INSTANCE)).toBeFalsy();
30- // });
31- // it(`CLASS`, () => {
32- // expect(guardFunction(CLASS)).toBeFalsy();
33- // });
34- // it(`null | NULL`, () => {
35- // expect(guardFunction(null)).toBeFalsy();
36- // expect(guardFunction(NULL)).toBeFalsy();
37- // });
38- // it(`'number' | Number`, () => {
39- // expect(guardFunction(NUMBER)).toBeFalsy();
40- // expect(guardFunction(NUMBER_INSTANCE)).toBeFalsy();
41- // expect(guardFunction(NUMBER_NEW_INSTANCE)).toBeFalsy();
42- // });
43- // it(`'object' | Object`, () => {
44- // expect(guardFunction(OBJECT_ONE)).toBeFalsy();
45- // expect(guardFunction(OBJECT_TWO)).toBeFalsy();
46- // });
47- // it(`'string' | String`, () => {
48- // expect(guardFunction(STRING)).toBeFalsy();
49- // expect(guardFunction(STRING_INSTANCE)).toBeFalsy();
50- // expect(guardFunction(STRING_NEW_INSTANCE)).toBeFalsy();
51- // });
52- // it(`'symbol'`, () => {
53- // expect(guardFunction(SYMBOL_NUMBER)).toBeFalsy();
54- // expect(guardFunction(SYMBOL_STRING)).toBeFalsy();
55- // });
56- // it(`'undefined'`, () => {
57- // expect(guardFunction(notDefined)).toBeFalsy();
58- // expect(guardFunction(UNDEFINED)).toBeFalsy();
59- // });
8+ it ( 'is DEFINED' , ( ) => expect ( guardFunction ) . toBeDefined ( ) ) ;
9+ it ( `function | Function` , ( ) => expect ( guardFunction ( FUNCTION ) ) . toBeTruthy ( ) ) ;
6010} ) ;
0 commit comments