generated from Exabyte-io/template-definitions
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathworkflow.test.js
37 lines (31 loc) · 1.24 KB
/
workflow.test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import { expect } from "chai";
import { createWorkflows, Workflow } from "../src/workflows";
import { createWorkflow } from "../src/workflows/create";
import { workflowData as allWorkflowData } from "../src/workflows/workflows";
describe("workflows", () => {
it("can all be created", () => {
const workflows = createWorkflows({});
workflows.map((wf) => {
// eslint-disable-next-line no-unused-expressions
expect(wf).to.exist;
// eslint-disable-next-line no-unused-expressions
expect(wf.isValid()).to.be.true;
const wfCopy = new Workflow(wf.toJSON());
// eslint-disable-next-line no-unused-expressions
expect(wfCopy.isValid()).to.be.true;
// expect(wf.validate()).to.be.true;
return null;
});
});
});
describe("workflow property", () => {
it("isMultiMaterial is read correctly", () => {
// Nudged Elastic Band is multi-material
const mmWorkflow = createWorkflow({
appName: "espresso",
workflowData: allWorkflowData.workflows.espresso.neb,
});
// eslint-disable-next-line no-unused-expressions
expect(mmWorkflow.isMultiMaterial).to.be.true;
});
});