1
|
*** Settings ***
|
2
|
Documentation A test suite with tests of graph construction.
|
3
|
...
|
4
|
... This test has a workflow that is created using keywords in
|
5
|
... the imported resource file.
|
6
|
...
|
7
|
Suite Setup Open Browser To Diagram
|
8
|
Suite Teardown Close Browser
|
9
|
Resource common.robot
|
10
|
|
11
|
*** Variables ***
|
12
|
${graphWrapper} //*[name()='g'][@id='graph']
|
13
|
${unconnectedNodeList} //div[@id='unconnectedNodeListComponent']
|
14
|
|
15
|
${componentCounter} //span[@class='component-counter']
|
16
|
${graphVersion} //span[@class='graph-version']
|
17
|
|
18
|
${vertex1} //*[name()='svg'][contains(@class, 'vertex')][@data-id='1']
|
19
|
${vertex2} //*[name()='svg'][contains(@class, 'vertex')][@data-id='2']
|
20
|
${vertex3} //*[name()='svg'][contains(@class, 'vertex')][@data-id='3']
|
21
|
${vertex4} //li[@data-id='4']
|
22
|
${vertex5} //*[name()='svg'][contains(@class, 'vertex')][@data-id='5']
|
23
|
${vertex6} //*[name()='svg'][contains(@class, 'vertex')][@data-id='6']
|
24
|
|
25
|
*** Test Cases ***
|
26
|
General
|
27
|
Title Should Be Visualization of large component diagrams
|
28
|
# check component counter
|
29
|
${count}= Get Text ${componentCounter}
|
30
|
Should Be Equal As Strings ${count} loaded components: 6
|
31
|
# check graph version
|
32
|
${version}= Get Text ${graphVersion}
|
33
|
Should Be Equal As Strings ${version} graph version: 1
|
34
|
# check vertices that should (not) be contained in viewport
|
35
|
Page Should Contain Element ${graphWrapper}${vertex1}
|
36
|
Page Should Contain Element ${graphWrapper}${vertex2}
|
37
|
Page Should Contain Element ${graphWrapper}${vertex3}
|
38
|
Page Should Not Contain Element ${graphWrapper}${vertex4}
|
39
|
Page Should Contain Element ${graphWrapper}${vertex5}
|
40
|
Page Should Contain Element ${graphWrapper}${vertex6}
|
41
|
# check vertices that should (not) be contained in unconnected node list
|
42
|
Page Should Not Contain Element ${unconnectedNodeList}${vertex1}
|
43
|
Page Should Not Contain Element ${unconnectedNodeList}${vertex2}
|
44
|
Page Should Not Contain Element ${unconnectedNodeList}${vertex3}
|
45
|
Page Should Contain Element ${unconnectedNodeList}${vertex4}
|
46
|
Page Should Not Contain Element ${unconnectedNodeList}${vertex5}
|
47
|
Page Should Not Contain Element ${unconnectedNodeList}${vertex6}
|
48
|
|
49
|
*** Keywords ***
|