@ripplo/testing 0.3.0 → 0.3.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/dist/{builder-CiAO8dEG.d.ts → builder-BGr5JvrY.d.ts} +7 -3
- package/dist/compiler.d.ts +1 -1
- package/dist/{engine-L0JWPRkj.d.ts → engine-Bo5nkg02.d.ts} +1 -1
- package/dist/express.d.ts +2 -2
- package/dist/fastify.d.ts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +14 -17
- package/dist/lockfile.d.ts +1 -1
- package/dist/nextjs.d.ts +2 -2
- package/package.json +3 -3
|
@@ -2,9 +2,13 @@ import { O as ObserverHandle, P as Precondition, l as PreconditionData, j as Tes
|
|
|
2
2
|
import { ObserverBudget } from '@ripplo/spec';
|
|
3
3
|
import { S as Step } from './step-De52hTLd.js';
|
|
4
4
|
|
|
5
|
-
interface
|
|
5
|
+
interface ObserverNeedsDescription {
|
|
6
|
+
readonly description: (text: string) => ObserverNeedsBudget;
|
|
7
|
+
}
|
|
8
|
+
interface ObserverNeedsBudget {
|
|
6
9
|
readonly budget: (tier: ObserverBudget) => ObserverNeedsInput;
|
|
7
|
-
|
|
10
|
+
}
|
|
11
|
+
interface ObserverNeedsInput {
|
|
8
12
|
readonly input: <TInput extends Record<string, string>>() => ObserverReady<TInput>;
|
|
9
13
|
}
|
|
10
14
|
interface ObserverReady<TInput extends Record<string, string>> {
|
|
@@ -73,7 +77,7 @@ interface RipploInstance<P extends PreconditionRegistry = PreconditionRegistry,
|
|
|
73
77
|
}
|
|
74
78
|
type RipploBuilder = RipploInstance;
|
|
75
79
|
declare function precondition(name: string): PreconditionNeedsSetup;
|
|
76
|
-
declare function observer(name: string):
|
|
80
|
+
declare function observer(name: string): ObserverNeedsDescription;
|
|
77
81
|
declare function test(id: string, options?: TestOptions): TestNeedsName;
|
|
78
82
|
declare function createRipplo<P extends PreconditionRegistry, O extends ObserverRegistry>(rawConfig: UserDslConfig, registries: RipploRegistries<P, O>): RipploInstance<P, O>;
|
|
79
83
|
|
package/dist/compiler.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Observer, Precondition, WorkflowSpec } from '@ripplo/spec';
|
|
2
|
-
import { d as RipploBuilder } from './builder-
|
|
2
|
+
import { d as RipploBuilder } from './builder-BGr5JvrY.js';
|
|
3
3
|
import { e as DslConfig } from './types-Degkxs1f.js';
|
|
4
4
|
import './step-De52hTLd.js';
|
|
5
5
|
import 'zod';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as PreconditionRegistry, a as ObserverRegistry, O as ObserverImplFn, P as PreconditionImpl, e as RipploInstance } from './builder-
|
|
1
|
+
import { c as PreconditionRegistry, a as ObserverRegistry, O as ObserverImplFn, P as PreconditionImpl, e as RipploInstance } from './builder-BGr5JvrY.js';
|
|
2
2
|
import { h as ObserverOutcome, C as CookieEntry, e as DslConfig, g as ObserverDefinition, k as PreconditionDefinition, U as UnimplementedItems, O as ObserverHandle, P as Precondition } from './types-Degkxs1f.js';
|
|
3
3
|
|
|
4
4
|
interface EngineResult {
|
package/dist/express.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Router } from 'express';
|
|
2
|
-
import { P as PreconditionEngine } from './engine-
|
|
3
|
-
import './builder-
|
|
2
|
+
import { P as PreconditionEngine } from './engine-Bo5nkg02.js';
|
|
3
|
+
import './builder-BGr5JvrY.js';
|
|
4
4
|
import './types-Degkxs1f.js';
|
|
5
5
|
import 'zod';
|
|
6
6
|
import './step-De52hTLd.js';
|
package/dist/fastify.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FastifyInstance } from 'fastify';
|
|
2
|
-
import { P as PreconditionEngine } from './engine-
|
|
3
|
-
import './builder-
|
|
2
|
+
import { P as PreconditionEngine } from './engine-Bo5nkg02.js';
|
|
3
|
+
import './builder-BGr5JvrY.js';
|
|
4
4
|
import './types-Degkxs1f.js';
|
|
5
5
|
import 'zod';
|
|
6
6
|
import './step-De52hTLd.js';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { O as ObserverImplFn, a as ObserverRegistry, P as PreconditionImpl, b as PreconditionRecord, c as PreconditionRegistry, R as ResolveDeps, d as RipploBuilder, e as RipploInstance, f as RipploRegistries, g as createRipplo, o as observer, p as precondition, t as test } from './builder-
|
|
1
|
+
export { O as ObserverImplFn, a as ObserverRegistry, P as PreconditionImpl, b as PreconditionRecord, c as PreconditionRegistry, R as ResolveDeps, d as RipploBuilder, e as RipploInstance, f as RipploRegistries, g as createRipplo, o as observer, p as precondition, t as test } from './builder-BGr5JvrY.js';
|
|
2
2
|
import { CompileResult } from './compiler.js';
|
|
3
3
|
export { CompiledTest, compile } from './compiler.js';
|
|
4
|
-
export { E as EngineImpls, a as EngineResult, b as ExecuteBatchOptions, N as NotImplemented, O as ObserverImplFnFor, P as PreconditionEngine, c as PreconditionImplFor, d as createEngine, n as notImplemented } from './engine-
|
|
4
|
+
export { E as EngineImpls, a as EngineResult, b as ExecuteBatchOptions, N as NotImplemented, O as ObserverImplFnFor, P as PreconditionEngine, c as PreconditionImplFor, d as createEngine, n as notImplemented } from './engine-Bo5nkg02.js';
|
|
5
5
|
import { C as CookieEntry } from './types-Degkxs1f.js';
|
|
6
6
|
export { c as CookieOptions, D as DEFAULT_IGNORE_PATHS, d as DEFAULT_WATCH_PATHS, e as DslConfig, f as ObserverContext, g as ObserverDefinition, O as ObserverHandle, a as ObserverInput, h as ObserverOutcome, P as Precondition, i as PreconditionDeps, S as SetupContext, T as TeardownContext, j as TestDefinition } from './types-Degkxs1f.js';
|
|
7
7
|
export { D as DslNodeInput } from './step-De52hTLd.js';
|
package/dist/index.js
CHANGED
|
@@ -33,25 +33,22 @@ function createRetryOutcome(reason) {
|
|
|
33
33
|
function createFailOutcome(reason) {
|
|
34
34
|
return { kind: "fail", reason };
|
|
35
35
|
}
|
|
36
|
+
function buildReady(state) {
|
|
37
|
+
return {
|
|
38
|
+
contract: () => makeObserverHandle(state)
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function buildNeedsInput(state) {
|
|
42
|
+
return {
|
|
43
|
+
input: () => buildReady(state)
|
|
44
|
+
};
|
|
45
|
+
}
|
|
36
46
|
function buildObserver(name) {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
budget = tier;
|
|
42
|
-
return self;
|
|
43
|
-
},
|
|
44
|
-
description(text) {
|
|
45
|
-
description = text;
|
|
46
|
-
return self;
|
|
47
|
-
},
|
|
48
|
-
input() {
|
|
49
|
-
return {
|
|
50
|
-
contract: () => makeObserverHandle({ budget, description, name })
|
|
51
|
-
};
|
|
52
|
-
}
|
|
47
|
+
return {
|
|
48
|
+
description: (description) => ({
|
|
49
|
+
budget: (budget) => buildNeedsInput({ budget, description, name })
|
|
50
|
+
})
|
|
53
51
|
};
|
|
54
|
-
return self;
|
|
55
52
|
}
|
|
56
53
|
|
|
57
54
|
// src/builder.ts
|
package/dist/lockfile.d.ts
CHANGED
package/dist/nextjs.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { P as PreconditionEngine } from './engine-
|
|
2
|
-
import './builder-
|
|
1
|
+
import { P as PreconditionEngine } from './engine-Bo5nkg02.js';
|
|
2
|
+
import './builder-BGr5JvrY.js';
|
|
3
3
|
import './types-Degkxs1f.js';
|
|
4
4
|
import 'zod';
|
|
5
5
|
import './step-De52hTLd.js';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ripplo/testing",
|
|
3
3
|
"description": "TypeScript DSL for defining and running Ripplo e2e workflow tests",
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist"
|
|
@@ -71,8 +71,8 @@
|
|
|
71
71
|
"tsup": "^8.5.1",
|
|
72
72
|
"typescript": "catalog:",
|
|
73
73
|
"vitest": "^4.1.4",
|
|
74
|
-
"@ripplo/
|
|
75
|
-
"@ripplo/
|
|
74
|
+
"@ripplo/spec": "^0.0.0",
|
|
75
|
+
"@ripplo/eslint-config": "0.0.0"
|
|
76
76
|
},
|
|
77
77
|
"peerDependencies": {
|
|
78
78
|
"dotenv": "^16.0.0 || ^17.0.0",
|