Skip to content

Commit

Permalink
Add integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bprb committed Aug 22, 2024
1 parent b1c1d2b commit be28003
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions cypress/integration/rendering/gantt.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,36 @@ describe('Gantt diagram', () => {
);
});

it('should position a dateFormat-based today marker', () => {
imgSnapshotTest(
`
gantt
title Reposition a today marker (using dateFormat)
dateFormat YYYY-MM-DD
today 2024-01-18
section Project
A task :a1, 2024-01-01, 30d
Another task :after a1, 20d
`,
{}
);
});

it('should position a duration-based today marker', () => {
imgSnapshotTest(
`
gantt
title Reposition a today marker (using duration)
dateFormat x
axisFormat %L ms
today 19ms
section Section1
A task: Draw 1: a1, 0, 28ms
`,
{}
);
});

it('should handle milliseconds', () => {
imgSnapshotTest(
`
Expand Down

0 comments on commit be28003

Please sign in to comment.