]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.tests.modelled.ui.ontology/graph/TestsUI.pgraph
Merge changes Ib64cf026,I238948da
[simantics/platform.git] / bundles / org.simantics.tests.modelled.ui.ontology / graph / TestsUI.pgraph
1 L0 = <http://www.simantics.org/Layer0-1.1>
2 TESTS = <http://www.simantics.org/Tests-1.0>
3 VP = <http://www.simantics.org/Viewpoint-1.2>
4 PROJECT = <http://www.simantics.org/Project-1.2>
5 MOD = <http://www.simantics.org/Modeling-1.2>
6 SILK = <http://www.simantics.org/Silk-1.1>
7 IMAGE = <http://www.simantics.org/Image2-1.2>
8
9 TestsUI = <http://www.simantics.org/TestsUI-1.0> : L0.Ontology
10     @L0.new
11     L0.HasResourceClass "org.simantics.tests.modelled.ui.ontology.TestsUIResource"
12
13 TestsUI.SCLMain : L0.SCLModule
14     L0.SCLModule.definition _ : L0.String 
15       @L0.loadString "scl/SCLMain.scl" 
16
17 TestsUI.testImage : IMAGE.PngImage
18   @L0.loadBytes "images/test.png"
19
20 TestsUI.testIgnoredImage : IMAGE.PngImage
21   @L0.loadBytes "images/testignored.gif"
22
23 TestsUI.testSuiteImage : IMAGE.PngImage
24   @L0.loadBytes "images/tsuite.png"
25
26 // Library containing all testing viewpoint contributions
27 TestsUI.Contributions : L0.Library
28
29 MBC = TestsUI.BrowseContext : VP.BrowseContext
30     VP.BrowseContext.IsIncludedIn PROJECT.ProjectBrowseContext
31
32 MBC.TestImageRule : VP.ImageRule
33
34 MBC
35     @VP.namedRelationChildRule    TestsUI.Contributions.STSSuites           L0.Entity                              L0.ConsistsOf TESTS.STSSuite
36     @VP.namedConstantImageRule    TestsUI.Contributions.SuiteImage          TESTS.STSSuite                         TestsUI.testSuiteImage
37     @VP.namedRelationChildRule    TestsUI.Contributions.STSTests            L0.Entity                              L0.ConsistsOf TESTS.STSTest
38     @VP.customImageRule           TESTS.STSTest                             MBC.TestImageRule
39
40 MBC
41     VP.BrowseContext.HasVisualsContribution _ : VP.VisualsContribution
42         VP.VisualsContribution.HasNodeType TESTS.STSSuite
43         VP.VisualsContribution.HasRule MBC.STSSuiteSorterRule
44
45 MBC.STSSuiteSorterRule : VP.SorterRule
46
47 MAC = TestsUI.ModelingActionContext : VP.BrowseContext
48     VP.BrowseContext.IsIncludedIn PROJECT.ProjectActionContext
49
50 ACTIONS = MAC.Actions : L0.Library
51
52 ACTIONS.NewSTSSuite
53   @MOD.sclAction "createSTSSuiteAction"
54 ACTIONS.NewSTSTest
55   @MOD.sclAction "createSTSTestAction"
56 ACTIONS.RunSTSTest
57   @MOD.sclAction "runSTSTestAction"
58
59 MAC
60     VP.BrowseContext.HasActionContribution TestsUI.Contributions.NewSTSSuite : VP.ActionContribution
61         L0.HasLabel "STS Suite"
62         VP.ActionContribution.HasImage TestsUI.testSuiteImage
63         VP.ActionContribution.HasCategory VP.NewActionCategory
64         VP.ActionContribution.HasNodeType
65             L0.Library
66         VP.ActionContribution.HasAction ACTIONS.NewSTSSuite
67     VP.BrowseContext.HasActionContribution TestsUI.Contributions.NewSTSTest : VP.ActionContribution
68         L0.HasLabel "STS Test"
69         VP.ActionContribution.HasImage TestsUI.testImage
70         VP.ActionContribution.HasCategory VP.NewActionCategory
71         VP.ActionContribution.HasNodeType
72             TESTS.STSSuite
73         VP.ActionContribution.HasAction ACTIONS.NewSTSTest
74     VP.BrowseContext.HasActionContribution _ : VP.ActionContribution
75         L0.HasLabel "Run"
76         VP.ActionContribution.HasImage SILK.control_play
77         VP.ActionContribution.HasCategory VP.EditActionCategory
78         VP.ActionContribution.HasNodeType TESTS.STSSuite
79         VP.ActionContribution.HasAction ACTIONS.RunSTSTest
80     VP.BrowseContext.HasActionContribution _ : VP.ActionContribution
81         L0.HasLabel "Run"
82         VP.ActionContribution.HasImage SILK.control_play
83         VP.ActionContribution.HasCategory VP.EditActionCategory
84         VP.ActionContribution.HasNodeType TESTS.STSTest
85         VP.ActionContribution.HasAction ACTIONS.RunSTSTest