@everyonesoftware/common 11.0.0 → 13.0.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/outputs/{characterWriteStream-Bhad6oGq.d.cts → characterWriteStream-DGlmRcFl.d.cts} +56 -1
- package/outputs/{characterWriteStream-Bhad6oGq.d.ts → characterWriteStream-DGlmRcFl.d.ts} +56 -1
- package/outputs/{chunk-R3D7NRFL.js → chunk-P4KLLRFY.js} +2 -2
- package/outputs/{chunk-U7O7WS5F.js → chunk-TUBXFCG4.js} +1950 -1909
- package/outputs/chunk-TUBXFCG4.js.map +1 -0
- package/outputs/sourceIndex.cjs +1950 -1905
- package/outputs/sourceIndex.cjs.map +1 -1
- package/outputs/sourceIndex.d.cts +212 -186
- package/outputs/sourceIndex.d.ts +212 -186
- package/outputs/sourceIndex.js +9 -1
- package/outputs/testIndex.cjs +763 -564
- package/outputs/testIndex.cjs.map +1 -1
- package/outputs/testIndex.d.cts +17 -2
- package/outputs/testIndex.d.ts +17 -2
- package/outputs/testIndex.js +31 -2
- package/outputs/testIndex.js.map +1 -1
- package/outputs/tests.cjs +2583 -2520
- package/outputs/tests.cjs.map +1 -1
- package/outputs/tests.js +2285 -2255
- package/outputs/tests.js.map +1 -1
- package/package.json +1 -1
- package/outputs/chunk-U7O7WS5F.js.map +0 -1
- /package/outputs/{chunk-R3D7NRFL.js.map → chunk-P4KLLRFY.js.map} +0 -0
package/outputs/testIndex.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { g as JavascriptIterable, S as SyncResult, P as PromiseAsyncResult, l as Type, I as Iterable, A as AsyncResult, C as CharacterWriteStream, a as Clock, D as DateTime } from './characterWriteStream-DGlmRcFl.cjs';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* A type that can be used to make assertions during a test.
|
|
@@ -526,4 +526,19 @@ declare class ConsoleTestRunner implements TestRunner {
|
|
|
526
526
|
printSummary(): AsyncResult<void>;
|
|
527
527
|
}
|
|
528
528
|
|
|
529
|
-
|
|
529
|
+
/**
|
|
530
|
+
* A {@link Clock} implementation that returns a configured {@link DateTime}.
|
|
531
|
+
*/
|
|
532
|
+
declare class FakeClock extends Clock {
|
|
533
|
+
private currentTime;
|
|
534
|
+
private constructor();
|
|
535
|
+
static create(currentTime?: DateTime): FakeClock;
|
|
536
|
+
/**
|
|
537
|
+
* Set the {@link DateTime} that this {@link FakeClock} will return.
|
|
538
|
+
* @param currentTime The {@link DateTime} that this {@link FakeClock} will return.
|
|
539
|
+
*/
|
|
540
|
+
setCurrentTime(currentTime: DateTime): this;
|
|
541
|
+
now(): DateTime;
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
export { AssertTest, BasicTestSkip, type ConsoleTestFunction, type ConsoleTestFunctionContainer, ConsoleTestRunner, FailedTest, FakeClock, SkippedTest, Test, TestAction, type TestActionType, TestRunner, TestSkip, test };
|
package/outputs/testIndex.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { g as JavascriptIterable, S as SyncResult, P as PromiseAsyncResult, l as Type, I as Iterable, A as AsyncResult, C as CharacterWriteStream, a as Clock, D as DateTime } from './characterWriteStream-DGlmRcFl.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* A type that can be used to make assertions during a test.
|
|
@@ -526,4 +526,19 @@ declare class ConsoleTestRunner implements TestRunner {
|
|
|
526
526
|
printSummary(): AsyncResult<void>;
|
|
527
527
|
}
|
|
528
528
|
|
|
529
|
-
|
|
529
|
+
/**
|
|
530
|
+
* A {@link Clock} implementation that returns a configured {@link DateTime}.
|
|
531
|
+
*/
|
|
532
|
+
declare class FakeClock extends Clock {
|
|
533
|
+
private currentTime;
|
|
534
|
+
private constructor();
|
|
535
|
+
static create(currentTime?: DateTime): FakeClock;
|
|
536
|
+
/**
|
|
537
|
+
* Set the {@link DateTime} that this {@link FakeClock} will return.
|
|
538
|
+
* @param currentTime The {@link DateTime} that this {@link FakeClock} will return.
|
|
539
|
+
*/
|
|
540
|
+
setCurrentTime(currentTime: DateTime): this;
|
|
541
|
+
now(): DateTime;
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
export { AssertTest, BasicTestSkip, type ConsoleTestFunction, type ConsoleTestFunctionContainer, ConsoleTestRunner, FailedTest, FakeClock, SkippedTest, Test, TestAction, type TestActionType, TestRunner, TestSkip, test };
|
package/outputs/testIndex.js
CHANGED
|
@@ -9,13 +9,42 @@ import {
|
|
|
9
9
|
TestRunner,
|
|
10
10
|
TestSkip,
|
|
11
11
|
test
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import
|
|
12
|
+
} from "./chunk-P4KLLRFY.js";
|
|
13
|
+
import {
|
|
14
|
+
Clock,
|
|
15
|
+
DateTime,
|
|
16
|
+
PreCondition
|
|
17
|
+
} from "./chunk-TUBXFCG4.js";
|
|
18
|
+
|
|
19
|
+
// tests/FakeClock.ts
|
|
20
|
+
var FakeClock = class _FakeClock extends Clock {
|
|
21
|
+
currentTime;
|
|
22
|
+
constructor(currentTime) {
|
|
23
|
+
PreCondition.assertNotUndefinedAndNotNull(currentTime, "currentTime");
|
|
24
|
+
super();
|
|
25
|
+
this.currentTime = currentTime;
|
|
26
|
+
}
|
|
27
|
+
static create(currentTime) {
|
|
28
|
+
return new _FakeClock(currentTime ?? DateTime.now());
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Set the {@link DateTime} that this {@link FakeClock} will return.
|
|
32
|
+
* @param currentTime The {@link DateTime} that this {@link FakeClock} will return.
|
|
33
|
+
*/
|
|
34
|
+
setCurrentTime(currentTime) {
|
|
35
|
+
this.currentTime = currentTime;
|
|
36
|
+
return this;
|
|
37
|
+
}
|
|
38
|
+
now() {
|
|
39
|
+
return this.currentTime;
|
|
40
|
+
}
|
|
41
|
+
};
|
|
14
42
|
export {
|
|
15
43
|
AssertTest,
|
|
16
44
|
BasicTestSkip,
|
|
17
45
|
ConsoleTestRunner,
|
|
18
46
|
FailedTest,
|
|
47
|
+
FakeClock,
|
|
19
48
|
SkippedTest,
|
|
20
49
|
Test,
|
|
21
50
|
TestAction,
|
package/outputs/testIndex.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
1
|
+
{"version":3,"sources":["../tests/FakeClock.ts"],"sourcesContent":["import { Clock, DateTime, PreCondition } from \"../sources\";\n\n/**\n * A {@link Clock} implementation that returns a configured {@link DateTime}.\n */\nexport class FakeClock extends Clock\n{\n private currentTime: DateTime;\n\n private constructor(currentTime: DateTime)\n {\n PreCondition.assertNotUndefinedAndNotNull(currentTime, \"currentTime\");\n\n super();\n\n this.currentTime = currentTime;\n }\n\n public static create(currentTime?: DateTime): FakeClock\n {\n return new FakeClock(currentTime ?? DateTime.now());\n }\n\n /**\n * Set the {@link DateTime} that this {@link FakeClock} will return.\n * @param currentTime The {@link DateTime} that this {@link FakeClock} will return.\n */\n public setCurrentTime(currentTime: DateTime): this\n {\n this.currentTime = currentTime;\n\n return this;\n }\n\n public now(): DateTime\n {\n return this.currentTime;\n }\n}"],"mappings":";;;;;;;;;;;;;;;;;;;AAKO,IAAM,YAAN,MAAM,mBAAkB,MAC/B;AAAA,EACY;AAAA,EAEA,YAAY,aACpB;AACI,iBAAa,6BAA6B,aAAa,aAAa;AAEpE,UAAM;AAEN,SAAK,cAAc;AAAA,EACvB;AAAA,EAEA,OAAc,OAAO,aACrB;AACI,WAAO,IAAI,WAAU,eAAe,SAAS,IAAI,CAAC;AAAA,EACtD;AAAA;AAAA;AAAA;AAAA;AAAA,EAMO,eAAe,aACtB;AACI,SAAK,cAAc;AAEnB,WAAO;AAAA,EACX;AAAA,EAEO,MACP;AACI,WAAO,KAAK;AAAA,EAChB;AACJ;","names":[]}
|