-
Notifications
You must be signed in to change notification settings - Fork 8
/
modified_tape.d.ts
92 lines (83 loc) · 3.49 KB
/
modified_tape.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
import nock2 = require('nock')
export = tape
declare function tape(name: string, cb: tape.TestCase): void;
declare function tape(name: string, opts: tape.TestOptions, cb: tape.TestCase): void;
declare function tape(cb: tape.TestCase): void;
declare function tape(opts: tape.TestOptions, cb: tape.TestCase): void;
declare namespace tape {
interface TestCase {
(test: Test): void;
}
interface TestOptions {
skip?: boolean;
timeout?: number;
}
interface StreamOptions {
objectMode?: boolean;
}
export function skip(name: string, cb: tape.TestCase): void;
export function only(name: string, cb: tape.TestCase): void;
export function createHarness(): typeof tape;
export function createStream(opts?: tape.StreamOptions): NodeJS.ReadableStream;
interface Test {
test(name: string, cb: tape.TestCase): void;
plan(n: number): void;
end(err?: any): void;
fail(msg?: string): void;
pass(msg?: string): void;
timeoutAfter(ms: number): void;
skip(msg?: string): void;
ok(value: any, msg?: string): void;
true(value: any, msg?: string): void;
assert(value: any, msg?: string): void;
notOk(value: any, msg?: string): void;
false(value: any, msg?: string): void;
notok(value: any, msg?: string): void;
error(err: any, msg?: string): void;
ifError(err: any, msg?: string): void;
ifErr(err: any, msg?: string): void;
iferror(err: any, msg?: string): void;
equal(a: any, b: any, msg?: string): void;
equals(a: any, b: any, msg?: string): void;
isEqual(a: any, b: any, msg?: string): void;
is(a: any, b: any, msg?: string): void;
strictEqual(a: any, b: any, msg?: string): void;
strictEquals(a: any, b: any, msg?: string): void;
notEqual(a: any, b: any, msg?: string): void;
notEquals(a: any, b: any, msg?: string): void;
notStrictEqual(a: any, b: any, msg?: string): void;
notStrictEquals(a: any, b: any, msg?: string): void;
isNotEqual(a: any, b: any, msg?: string): void;
isNot(a: any, b: any, msg?: string): void;
not(a: any, b: any, msg?: string): void;
doesNotEqual(a: any, b: any, msg?: string): void;
isInequal(a: any, b: any, msg?: string): void;
deepEqual(a: any, b: any, msg?: string): void;
deepEquals(a: any, b: any, msg?: string): void;
isEquivalent(a: any, b: any, msg?: string): void;
same(a: any, b: any, msg?: string): void;
notDeepEqual(a: any, b: any, msg?: string): void;
notEquivalent(a: any, b: any, msg?: string): void;
notDeeply(a: any, b: any, msg?: string): void;
notSame(a: any, b: any, msg?: string): void;
isNotDeepEqual(a: any, b: any, msg?: string): void;
isNotDeeply(a: any, b: any, msg?: string): void;
isNotEquivalent(a: any, b: any, msg?: string): void;
isInequivalent(a: any, b: any, msg?: string): void;
deepLooseEqual(a: any, b: any, msg?: string): void;
looseEqual(a: any, b: any, msg?: string): void;
looseEquals(a: any, b: any, msg?: string): void;
notDeepLooseEqual(a: any, b: any, msg?: string): void;
notLooseEqual(a: any, b: any, msg?: string): void;
notLooseEquals(a: any, b: any, msg?: string): void;
throws(fn: () => void, msg?: string): void;
throws(fn: () => void, exceptionExpected: RegExp | (() => void), msg?: string): void;
doesNotThrow(fn: () => void, msg?: string): void;
doesNotThrow(fn: () => void, exceptionExpected: RegExp | (() => void), msg?: string): void;
comment(msg: string): void;
}
}
// MODIFICATION
declare namespace tape {
export import nock = nock2
}