Skip to content

The open alternative to Salesforce, designed for AI.

test(upgrade): assert sequence-runner error structurally instead of snapshot (#20213)

Félix Malfait5bf7e8b10188
diff --git a/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/__snapshots__/failing-sequence-runner.integration-spec.ts.snap b/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/__snapshots__/failing-sequence-runner.integration-spec.ts.snap
deleted file mode 100644
index b814c5ded74..00000000000
--- a/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/__snapshots__/failing-sequence-runner.integration-spec.ts.snap
+++ /dev/null
@@ -1,3 +0,0 @@
-// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
-
-exports[`UpgradeSequenceRunnerService — failing sequence (integration) should throw when cursor command is not found in the sequence 1`] = `"Step "RemovedCommand" not found in upgrade sequence. The sequence only covers versions [1.21.0, 1.22.0, 1.23.0, 2.0.0, 2.1.0, 2.2.0]. Please upgrade to 1.21.0 first."`;
diff --git a/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/failing-sequence-runner.integration-spec.ts b/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/failing-sequence-runner.integration-spec.ts
index 49ec5e18194..5403f710b0e 100644
--- a/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/failing-sequence-runner.integration-spec.ts
+++ b/packages/twenty-server/test/integration/upgrade/suites/sequence-runner/failing-sequence-runner.integration-spec.ts
@@ -106,7 +106,7 @@ describe('UpgradeSequenceRunnerService — failing sequence (integration)', () =
sequence,
options: DEFAULT_OPTIONS,
}),
- ).rejects.toThrowErrorMatchingSnapshot();
+ ).rejects.toThrow(/Step "RemovedCommand" not found in upgrade sequence/);
});
it('should throw when workspace cursors are outside the current slice', async () => {