risei 1.1.1 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -16
- package/index.js +1 -1
- package/package.json +6 -5
- package/system/Risei.js +1 -1
- package/system/TestFinder.js +19 -3
- package/system/TestRunner.js +1 -1
- package/tests/other-tests/ASpoofingFixture.tests.js +0 -242
- package/tests/other-tests/SpoofClassesFixture.tests.js +0 -130
- package/tests/other-tests/SpoofObjectsFixture.tests.js +0 -95
- package/tests/other-tests/SpoofTuple.tests.js +0 -93
- package/tests/other-tests/TotalComparer.tests.js +0 -920
- package/tests/other-tests/package.json +0 -7
- package/tests/risei-tests/ASpoofingFixtureTests.rt.js +0 -51
- package/tests/risei-tests/MomentTests.rt.js +0 -103
- package/tests/risei-tests/SpoofTupleTests.rt.js +0 -274
- package/tests/risei-tests/TestFrameChooserTests.rt.js +0 -74
- package/tests/risei-tests/TestFrameTests.rt.js +0 -84
- package/tests/risei-tests/TestStagesTests.rt.js +0 -99
- package/tests/risei-tests/TestTupleTests.rt.js +0 -140
- package/tests/risei-tests/TotalComparerTests.rt.js +0 -184
- package/tests/risei-tests/TotalCopierTests.rt.js +0 -74
- package/tests/risei-tests/TotalDisplayerTests.rt.js +0 -186
- package/tests/risei-tests/TypeAnalyzerTests.rt.js +0 -29
- package/tests/risei-tests/TypeIdentifierTests.rt.js +0 -44
- package/tests/self-tests/SelfTests.outward-rt.js +0 -583
- package/tests/target-objects/CompositionModel.js +0 -38
- package/tests/target-objects/ConditionalThrowModel.js +0 -11
- package/tests/target-objects/CountModel.js +0 -46
- package/tests/target-objects/DomModel.js +0 -37
- package/tests/target-objects/MixedContents.js +0 -33
- package/tests/target-objects/MutationModel.js +0 -27
- package/tests/target-objects/ObjectCompositionModel.js +0 -34
- package/tests/target-objects/PolySpoofableInner.js +0 -30
- package/tests/target-objects/PolySpoofableOuter.js +0 -52
- package/tests/target-objects/PropertiesModel.js +0 -47
- package/tests/target-objects/Returner.js +0 -9
- package/tests/target-objects/SearchModel.js +0 -25
- package/tests/target-objects/SortModel.js +0 -91
- package/tests/target-objects/SpoofCaller.js +0 -24
- package/tests/target-objects/Spoofable.js +0 -36
- package/tests/target-objects/SpoofableArgsCaller.js +0 -33
- package/tests/target-objects/StateModel.js +0 -34
- package/tests/target-objects/StaticModel.js +0 -17
- package/tests/target-objects/TestableModel.js +0 -47
- package/tests/topic-tests/TopicTests.outward-rt.js +0 -354
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
/**/
|
|
2
|
-
|
|
3
|
-
import { SpoofTuple } from "../../system/SpoofTuple.js";
|
|
4
|
-
import { expect } from "chai";
|
|
5
|
-
|
|
6
|
-
describe("SpoofTuple", () => {
|
|
7
|
-
/* Some cases here are effectively impossible to test directly in self-tests, at least
|
|
8
|
-
without complicated workarounds, because of how SpoofTuple is used by Kitten tests. */
|
|
9
|
-
|
|
10
|
-
describe("isNotASpoof()", () => {
|
|
11
|
-
it("Should return true when arg is undefined.", /* good */ () => {
|
|
12
|
-
let nonce = undefined;
|
|
13
|
-
|
|
14
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
15
|
-
|
|
16
|
-
expect(actual).to.be.true;
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it("Should return true when arg is null.", /* good */ () => {
|
|
20
|
-
let nonce = null;
|
|
21
|
-
|
|
22
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
23
|
-
|
|
24
|
-
expect(actual).to.be.true;
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
it("Should return true when arg is a string.", /* good */ () => {
|
|
28
|
-
let nonce = "text";
|
|
29
|
-
|
|
30
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
31
|
-
|
|
32
|
-
expect(actual).to.be.true;
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
it("Should return true when arg is a value, such as a number.", /* good */ () => {
|
|
36
|
-
let nonce = 37;
|
|
37
|
-
|
|
38
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
39
|
-
|
|
40
|
-
expect(actual).to.be.true;
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
it("Should return true when arg is a predefined JavaScript Object, such as a Map.", /* good */ () => {
|
|
44
|
-
let nonce = new Map();
|
|
45
|
-
|
|
46
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
47
|
-
|
|
48
|
-
expect(actual).to.be.true;
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
it("Should return true when arg contains SpoofTuple properties but also .not.", /* good */ () => {
|
|
52
|
-
let nonce = { on: "on-arg", of: "of-arg", as: "as-arg", not: true };
|
|
53
|
-
|
|
54
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
55
|
-
|
|
56
|
-
expect(actual).to.be.true;
|
|
57
|
-
});
|
|
58
|
-
|
|
59
|
-
it("Should return true when arg contains SpoofTuple properties but also .skip.", /* good */ () => {
|
|
60
|
-
let nonce = { on: "on-arg", of: "of-arg", as: "as-arg", skip: true };
|
|
61
|
-
|
|
62
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
63
|
-
|
|
64
|
-
expect(actual).to.be.true;
|
|
65
|
-
});
|
|
66
|
-
|
|
67
|
-
it("Should return true when arg doesn't contain any SpoofTuple properties.", /* good */ () => {
|
|
68
|
-
let nonce = { notOn: true, notOf: "true", notAs: "not-as" };
|
|
69
|
-
|
|
70
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
71
|
-
|
|
72
|
-
expect(actual).to.be.true;
|
|
73
|
-
});
|
|
74
|
-
|
|
75
|
-
it("Should return false when arg contains any short-named " +
|
|
76
|
-
"SpoofTuple property, but neither .not nor .skip.", /* good */ () => {
|
|
77
|
-
let nonce = { on: "some-class" };
|
|
78
|
-
|
|
79
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
80
|
-
|
|
81
|
-
expect(actual).to.be.false;
|
|
82
|
-
});
|
|
83
|
-
|
|
84
|
-
it("Should return false when arg contains any long-named " +
|
|
85
|
-
"SpoofTuple property, but neither .not nor .skip.", /* good */ () => {
|
|
86
|
-
let nonce = { method: "some-method" };
|
|
87
|
-
|
|
88
|
-
let actual = SpoofTuple.isNotASpoof(nonce);
|
|
89
|
-
|
|
90
|
-
expect(actual).to.be.false;
|
|
91
|
-
});
|
|
92
|
-
});
|
|
93
|
-
});
|