-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug: #2796 Signed-off-by: Florian ROUËNÉ <florian.rouene@obeosoft.com>
- Loading branch information
Showing
78 changed files
with
3,797 additions
and
197 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
/******************************************************************************* | ||
* Copyright (c) 2024 Obeo. | ||
* This program and the accompanying materials | ||
* are made available under the terms of the Eclipse Public License v2.0 | ||
* which accompanies this distribution, and is available at | ||
* https://www.eclipse.org/legal/epl-2.0/ | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* | ||
* Contributors: | ||
* Obeo - initial API and implementation | ||
*******************************************************************************/ | ||
|
||
import { Project } from '../../../pages/Project'; | ||
import { Flow } from '../../../usecases/Flow'; | ||
import { Explorer } from '../../../workbench/Explorer'; | ||
import { Diagram } from '../../../workbench/Diagram'; | ||
|
||
const projectName = 'Cypress - flow'; | ||
|
||
describe('Flow', () => { | ||
context('Given a flow project with a robot document', () => { | ||
let projectId: string = ''; | ||
beforeEach(() => | ||
new Flow().createRobotProject(projectName).then((createdProjectData) => { | ||
projectId = createdProjectData.projectId; | ||
new Project().visit(projectId); | ||
}) | ||
); | ||
|
||
afterEach(() => cy.deleteProject(projectId)); | ||
|
||
context('When we interact with the flow diagram', () => { | ||
it('Then I can create a topography diagram', () => { | ||
const explorer = new Explorer(); | ||
const diagram = new Diagram(); | ||
explorer.getExplorerView().contains('robot'); | ||
explorer.expand('robot'); | ||
explorer.createRepresentation('Robot', 'Topography', 'diagramTopography'); | ||
diagram.getDiagram('diagramTopography').should('exist'); | ||
diagram.getNodes('diagramTopography', 'Central_Unit').should('exist'); | ||
}); | ||
|
||
it('Then I can create a topography unsynchronized diagram', () => { | ||
const explorer = new Explorer(); | ||
const diagram = new Diagram(); | ||
explorer.getExplorerView().contains('robot'); | ||
explorer.expand('robot'); | ||
explorer.createRepresentation('Robot', 'Topography unsynchronized', 'diagramTopographyUnsynchronized'); | ||
diagram.getDiagram('diagramTopographyUnsynchronized').should('exist'); | ||
diagram.getNodes('diagramTopographyUnsynchronized', 'Central_Unit').should('not.exist'); | ||
}); | ||
|
||
it('Then I can create a topography with auto layout diagram', () => { | ||
const explorer = new Explorer(); | ||
const diagram = new Diagram(); | ||
explorer.getExplorerView().contains('robot'); | ||
explorer.expand('robot'); | ||
explorer.createRepresentation('Robot', 'Topography with auto layout', 'diagramTopographyWithAutoLayout'); | ||
diagram.getDiagram('diagramTopographyWithAutoLayout').should('exist'); | ||
diagram.getNodes('diagramTopographyWithAutoLayout', 'Description').should('exist'); | ||
}); | ||
}); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.