#945 Support for notes

This commit is contained in:
Knut Sveidqvist
2019-10-06 10:52:37 +02:00
parent 3b731282e3
commit 1cb52a602a
5 changed files with 174 additions and 17 deletions

View File

@@ -13,6 +13,49 @@ describe('State diagram', () => {
);
cy.get('svg');
});
it('should render a state with a note', () => {
imgSnapshotTest(
`
stateDiagram
State1: The state with a note
note right of State1
Important information! You can write
notes.
end note
`,
{ logLevel: 0 }
);
cy.get('svg');
});
it('should render a state with on the left side when so specified', () => {
imgSnapshotTest(
`
stateDiagram
State1: The state with a note
note left of State1
Important information! You can write
notes.
end note
`,
{ logLevel: 0 }
);
cy.get('svg');
});
it('should render a state with a note together with another state', () => {
imgSnapshotTest(
`
stateDiagram
State1: The state with a note
note right of State1
Important information! You can write
notes.
end note
State1 --> State2
`,
{ logLevel: 0 }
);
cy.get('svg');
});
it('should render a states with descriptions including multi-line descriptions', () => {
imgSnapshotTest(
`