1 | import unittest |
---|
2 | import sys |
---|
3 | from PyQt5 import QtGui |
---|
4 | from PyQt5 import QtWidgets |
---|
5 | |
---|
6 | # Prepare the general QApplication instance |
---|
7 | app = QtWidgets.QApplication(sys.argv) |
---|
8 | |
---|
9 | # Main Window |
---|
10 | from MainWindow.UnitTesting import AboutBoxTest |
---|
11 | from MainWindow.UnitTesting import DataExplorerTest |
---|
12 | from MainWindow.UnitTesting import WelcomePanelTest |
---|
13 | from MainWindow.UnitTesting import DroppableDataLoadWidgetTest |
---|
14 | from MainWindow.UnitTesting import GuiManagerTest |
---|
15 | from MainWindow.UnitTesting import MainWindowTest |
---|
16 | |
---|
17 | ## Plotting |
---|
18 | from Plotting.UnitTesting import AddTextTest |
---|
19 | from Plotting.UnitTesting import PlotHelperTest |
---|
20 | from Plotting.UnitTesting import WindowTitleTest |
---|
21 | from Plotting.UnitTesting import ScalePropertiesTest |
---|
22 | from Plotting.UnitTesting import SetGraphRangeTest |
---|
23 | from Plotting.UnitTesting import LinearFitTest |
---|
24 | from Plotting.UnitTesting import PlotPropertiesTest |
---|
25 | from Plotting.UnitTesting import PlotUtilitiesTest |
---|
26 | from Plotting.UnitTesting import ColorMapTest |
---|
27 | from Plotting.UnitTesting import BoxSumTest |
---|
28 | from Plotting.UnitTesting import SlicerModelTest |
---|
29 | from Plotting.UnitTesting import SlicerParametersTest |
---|
30 | from Plotting.UnitTesting import PlotterBaseTest |
---|
31 | from Plotting.UnitTesting import PlotterTest |
---|
32 | from Plotting.UnitTesting import Plotter2DTest |
---|
33 | |
---|
34 | # Calculators |
---|
35 | from Calculators.UnitTesting import KiessigCalculatorTest |
---|
36 | from Calculators.UnitTesting import DensityCalculatorTest |
---|
37 | from Calculators.UnitTesting import GenericScatteringCalculatorTest |
---|
38 | from Calculators.UnitTesting import SLDCalculatorTest |
---|
39 | from Calculators.UnitTesting import SlitSizeCalculatorTest |
---|
40 | from Calculators.UnitTesting import ResolutionCalculatorPanelTest |
---|
41 | from Calculators.UnitTesting import DataOperationUtilityTest |
---|
42 | |
---|
43 | # Utilities |
---|
44 | from Utilities.UnitTesting import GuiUtilsTest |
---|
45 | from Utilities.UnitTesting import SasviewLoggerTest |
---|
46 | from Utilities.UnitTesting import GridPanelTest |
---|
47 | from Utilities.UnitTesting import ModelEditorTest |
---|
48 | from Utilities.UnitTesting import PluginDefinitionTest |
---|
49 | from Utilities.UnitTesting import TabbedModelEditorTest |
---|
50 | from Utilities.UnitTesting import AddMultEditorTest |
---|
51 | from Utilities.UnitTesting import ReportDialogTest |
---|
52 | |
---|
53 | # Unit Testing |
---|
54 | from UnitTesting import TestUtilsTest |
---|
55 | |
---|
56 | # Perspectives |
---|
57 | # Fitting |
---|
58 | from Perspectives.Fitting.UnitTesting import FittingWidgetTest |
---|
59 | from Perspectives.Fitting.UnitTesting import FittingPerspectiveTest |
---|
60 | from Perspectives.Fitting.UnitTesting import FittingLogicTest |
---|
61 | from Perspectives.Fitting.UnitTesting import FittingUtilitiesTest |
---|
62 | from Perspectives.Fitting.UnitTesting import FitPageTest |
---|
63 | from Perspectives.Fitting.UnitTesting import FittingOptionsTest |
---|
64 | from Perspectives.Fitting.UnitTesting import MultiConstraintTest |
---|
65 | from Perspectives.Fitting.UnitTesting import ComplexConstraintTest |
---|
66 | from Perspectives.Fitting.UnitTesting import ConstraintWidgetTest |
---|
67 | |
---|
68 | # Invariant |
---|
69 | from Perspectives.Invariant.UnitTesting import InvariantPerspectiveTest |
---|
70 | |
---|
71 | # Inversion |
---|
72 | from Perspectives.Inversion.UnitTesting import InversionPerspectiveTest |
---|
73 | |
---|
74 | def suite(): |
---|
75 | suites = ( |
---|
76 | # Plotting |
---|
77 | unittest.makeSuite(Plotter2DTest.Plotter2DTest, 'test'), |
---|
78 | unittest.makeSuite(PlotHelperTest.PlotHelperTest, 'test'), |
---|
79 | unittest.makeSuite(AddTextTest.AddTextTest, 'test'), |
---|
80 | unittest.makeSuite(WindowTitleTest.WindowTitleTest, 'test'), |
---|
81 | unittest.makeSuite(ScalePropertiesTest.ScalePropertiesTest, 'test'), |
---|
82 | unittest.makeSuite(SetGraphRangeTest.SetGraphRangeTest, 'test'), |
---|
83 | unittest.makeSuite(LinearFitTest.LinearFitTest, 'test'), |
---|
84 | unittest.makeSuite(PlotPropertiesTest.PlotPropertiesTest, 'test'), |
---|
85 | unittest.makeSuite(PlotUtilitiesTest.PlotUtilitiesTest, 'test'), |
---|
86 | unittest.makeSuite(ColorMapTest.ColorMapTest, 'test'), |
---|
87 | unittest.makeSuite(BoxSumTest.BoxSumTest, 'test'), |
---|
88 | unittest.makeSuite(SlicerModelTest.SlicerModelTest, 'test'), |
---|
89 | unittest.makeSuite(SlicerParametersTest.SlicerParametersTest, 'test'), |
---|
90 | unittest.makeSuite(PlotterBaseTest.PlotterBaseTest, 'test'), |
---|
91 | unittest.makeSuite(PlotterTest.PlotterTest, 'test'), |
---|
92 | |
---|
93 | # Main window |
---|
94 | unittest.makeSuite(DataExplorerTest.DataExplorerTest, 'test'), |
---|
95 | unittest.makeSuite(DroppableDataLoadWidgetTest.DroppableDataLoadWidgetTest, 'test'), |
---|
96 | unittest.makeSuite(MainWindowTest.MainWindowTest, 'test'), |
---|
97 | unittest.makeSuite(GuiManagerTest.GuiManagerTest, 'test'), |
---|
98 | unittest.makeSuite(AboutBoxTest.AboutBoxTest, 'test'), |
---|
99 | unittest.makeSuite(WelcomePanelTest.WelcomePanelTest, 'test'), |
---|
100 | |
---|
101 | # Utilities |
---|
102 | unittest.makeSuite(TestUtilsTest.TestUtilsTest, 'test'), |
---|
103 | unittest.makeSuite(SasviewLoggerTest.SasviewLoggerTest, 'test'), |
---|
104 | unittest.makeSuite(GuiUtilsTest.GuiUtilsTest, 'test'), |
---|
105 | unittest.makeSuite(GuiUtilsTest.DoubleValidatorTest, 'test'), |
---|
106 | unittest.makeSuite(GuiUtilsTest.HashableStandardItemTest, 'test'), |
---|
107 | unittest.makeSuite(GridPanelTest.BatchOutputPanelTest, 'test'), |
---|
108 | unittest.makeSuite(ModelEditorTest.ModelEditorTest, 'test'), |
---|
109 | unittest.makeSuite(PluginDefinitionTest.PluginDefinitionTest, 'test'), |
---|
110 | unittest.makeSuite(TabbedModelEditorTest.TabbedModelEditorTest,'test'), |
---|
111 | unittest.makeSuite(AddMultEditorTest.AddMultEditorTest, 'test'), |
---|
112 | unittest.makeSuite(ReportDialogTest.ReportDialogTest, 'test'), |
---|
113 | |
---|
114 | # Calculators |
---|
115 | unittest.makeSuite(KiessigCalculatorTest.KiessigCalculatorTest, 'test'), |
---|
116 | unittest.makeSuite(DensityCalculatorTest.DensityCalculatorTest, 'test'), |
---|
117 | unittest.makeSuite(GenericScatteringCalculatorTest.GenericScatteringCalculatorTest, 'test'), |
---|
118 | unittest.makeSuite(SLDCalculatorTest.SLDCalculatorTest, 'test'), |
---|
119 | unittest.makeSuite(SlitSizeCalculatorTest.SlitSizeCalculatorTest, 'test'), |
---|
120 | unittest.makeSuite(ResolutionCalculatorPanelTest.ResolutionCalculatorPanelTest, 'test'), |
---|
121 | unittest.makeSuite(DataOperationUtilityTest.DataOperationUtilityTest, 'test'), |
---|
122 | |
---|
123 | # Perspectives |
---|
124 | # Fitting |
---|
125 | unittest.makeSuite(FittingPerspectiveTest.FittingPerspectiveTest, 'test'), |
---|
126 | unittest.makeSuite(FittingWidgetTest.FittingWidgetTest, 'test'), |
---|
127 | unittest.makeSuite(FittingLogicTest.FittingLogicTest, 'test'), |
---|
128 | unittest.makeSuite(FittingUtilitiesTest.FittingUtilitiesTest, 'test'), |
---|
129 | unittest.makeSuite(FitPageTest.FitPageTest, 'test'), |
---|
130 | unittest.makeSuite(FittingOptionsTest.FittingOptionsTest, 'test'), |
---|
131 | unittest.makeSuite(MultiConstraintTest.MultiConstraintTest, 'test'), |
---|
132 | unittest.makeSuite(ConstraintWidgetTest.ConstraintWidgetTest, 'test'), |
---|
133 | unittest.makeSuite(ComplexConstraintTest.ComplexConstraintTest, 'test'), |
---|
134 | |
---|
135 | # Invariant |
---|
136 | unittest.makeSuite(InvariantPerspectiveTest.InvariantPerspectiveTest, 'test'), |
---|
137 | # Inversion |
---|
138 | unittest.makeSuite(InversionPerspectiveTest.InversionTest, 'test'), |
---|
139 | ) |
---|
140 | return unittest.TestSuite(suites) |
---|
141 | |
---|
142 | if __name__ == "__main__": |
---|
143 | unittest.main(defaultTest="suite") |
---|
144 | |
---|