@flemist/test-variants 5.0.0 → 5.0.1
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 +4 -0
- package/build/browser/index.cjs +1 -1
- package/build/browser/index.mjs +1 -1
- package/build/common/index.cjs +1 -1
- package/build/common/index.mjs +1 -1
- package/build/common/test-variants/iterator/types.d.ts +4 -0
- package/build/common/test-variants/types.d.ts +4 -0
- package/build/createTestVariants-BE_TQ9u5.mjs +1018 -0
- package/build/createTestVariants-Cmx68kHs.js +4 -0
- package/build/node/index.cjs +1 -1
- package/build/node/index.mjs +34 -29
- package/package.json +1 -1
- package/build/createTestVariants-BL9wiuRD.mjs +0 -1014
- package/build/createTestVariants-CpzwjKTs.js +0 -4
package/README.md
CHANGED
|
@@ -226,6 +226,10 @@ const result = await testVariants({
|
|
|
226
226
|
// all errors from them are collected and used as initial constraints for findBestError
|
|
227
227
|
// Useful when you need to continue best error search after testVariants restart
|
|
228
228
|
useToFindBestError: false,
|
|
229
|
+
// Same as limitArgOnError
|
|
230
|
+
limitArg: boolean | Function, // default: false
|
|
231
|
+
// Extend template with extra args from limit if they are missing
|
|
232
|
+
extendTemplates: boolean, // default: false
|
|
229
233
|
},
|
|
230
234
|
|
|
231
235
|
// Called when an error occurs in the test
|
package/build/browser/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../createTestVariants-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../createTestVariants-Cmx68kHs.js");exports.createTestVariants=e.createTestVariants;
|
package/build/browser/index.mjs
CHANGED
package/build/common/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../createTestVariants-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../createTestVariants-Cmx68kHs.js");exports.createTestVariants=e.createTestVariants;
|
package/build/common/index.mjs
CHANGED
|
@@ -14,6 +14,10 @@ export type AddLimitOptions<Args extends Obj> = {
|
|
|
14
14
|
error?: unknown;
|
|
15
15
|
/** Number of tests run when this limit is applied */
|
|
16
16
|
tests?: null | number;
|
|
17
|
+
/** Limit per-arg indexes; boolean enables/disables, function for custom per-arg logic */
|
|
18
|
+
limitArg?: null | boolean | LimitArgOnError;
|
|
19
|
+
/** Extend template with extra args from limit if they are missing */
|
|
20
|
+
extendTemplates?: null | boolean;
|
|
17
21
|
};
|
|
18
22
|
/** Options for creating test variants iterator */
|
|
19
23
|
export type VariantsIteratorOptions<Args extends Obj> = {
|
|
@@ -93,6 +93,10 @@ export type SaveErrorVariantsOptions<Args extends Obj, SavedArgs = Args> = {
|
|
|
93
93
|
jsonToArgs?: null | ((json: SavedArgs) => ArgsWithSeed<Args>);
|
|
94
94
|
/** Use saved errors to set findBestError limits instead of throwing on replay */
|
|
95
95
|
useToFindBestError?: null | boolean;
|
|
96
|
+
/** Limit per-arg indexes; boolean enables/disables, function for custom per-arg logic */
|
|
97
|
+
limitArg?: null | boolean | LimitArgOnError;
|
|
98
|
+
/** Extend template with extra args from limit if they are missing */
|
|
99
|
+
extendTemplates?: null | boolean;
|
|
96
100
|
};
|
|
97
101
|
/** Options passed to test function */
|
|
98
102
|
export type TestOptions = {
|