380
|
1 |
"{ Encoding: utf8 }"
|
|
2 |
|
350
|
3 |
"{ Package: 'stx:goodies/builder/quickSelfTest' }"
|
|
4 |
|
|
5 |
"{ NameSpace: Smalltalk }"
|
|
6 |
|
|
7 |
StandaloneStartup subclass:#RunUnitTestsStart
|
|
8 |
instanceVariableNames:''
|
|
9 |
classVariableNames:''
|
|
10 |
poolDictionaries:''
|
|
11 |
category:'tests-Regression'
|
|
12 |
!
|
|
13 |
|
|
14 |
!RunUnitTestsStart class methodsFor:'documentation'!
|
|
15 |
|
|
16 |
documentation
|
|
17 |
"
|
|
18 |
documentation to be added.
|
|
19 |
|
|
20 |
[author:]
|
|
21 |
sr
|
|
22 |
|
|
23 |
[instance variables:]
|
|
24 |
|
|
25 |
[class variables:]
|
|
26 |
|
|
27 |
[see also:]
|
|
28 |
|
|
29 |
"
|
|
30 |
! !
|
|
31 |
|
449
|
32 |
!RunUnitTestsStart class methodsFor:'constants'!
|
|
33 |
|
|
34 |
usage
|
|
35 |
Stderr cr.
|
|
36 |
Stderr nextPutLine:' --help............................this infromation'.
|
|
37 |
Stderr nextPutLine:' --settingsFile....................path to a stx settings file (may to set compiler options)'.
|
|
38 |
Stderr nextPutLine:' --runOnlyExpeccoUnitTests.........run only expecco related test cases'.
|
|
39 |
Stderr nextPutLine:' --resultFile......................path to a file for storing the result as xml'.
|
|
40 |
Stderr nextPutLine:' --forceTestCase...................class name of a test case (only this test case will be executed)'.
|
|
41 |
! !
|
|
42 |
|
|
43 |
!RunUnitTestsStart class methodsFor:'startup'!
|
350
|
44 |
|
380
|
45 |
main:argv
|
396
|
46 |
|allPackageIDs|
|
|
47 |
|
380
|
48 |
self verboseInfo:('starting application').
|
|
49 |
self startStartBlockProcess.
|
|
50 |
|
383
|
51 |
"install a global handler,
|
|
52 |
which suppresses the updating of the change file"
|
|
53 |
Processor activeProcess exceptionHandlerSet
|
|
54 |
on:(Class updateChangeFileQuerySignal)
|
|
55 |
do:[:ex | ex proceedWith:false].
|
381
|
56 |
|
383
|
57 |
"ensure that required packages are present"
|
396
|
58 |
allPackageIDs := Smalltalk allPackageIDs.
|
383
|
59 |
#(
|
|
60 |
'stx:goodies/sunit'
|
396
|
61 |
'stx:libcompat'
|
|
62 |
'stx:libjavascript'
|
383
|
63 |
'stx:goodies/regression'
|
450
|
64 |
'exept:libcrypt'
|
383
|
65 |
) do:[:eachPackage |
|
396
|
66 |
(allPackageIDs includes:eachPackage) ifFalse:[
|
397
|
67 |
Smalltalk isStandAloneApp ifTrue:[
|
|
68 |
Stdout showCR:'error: missing package ', eachPackage.
|
|
69 |
Smalltalk exit:1.
|
|
70 |
] ifFalse:[
|
|
71 |
Transcript showCR:'error: missing package ', eachPackage.
|
|
72 |
].
|
383
|
73 |
].
|
|
74 |
].
|
|
75 |
|
|
76 |
"run the unit tests"
|
401
|
77 |
RunUnitTests runWithCompiledUnitTestClasses:true.
|
441
|
78 |
RegressionTests::IntegerTest. "/ just to get the ref for building make files
|
449
|
79 |
!
|
|
80 |
|
|
81 |
setupSmalltalkFromArguments:argv
|
|
82 |
(argv includes:'/?') ifTrue:[
|
|
83 |
self usage.
|
|
84 |
AbortOperationRequest raise.
|
|
85 |
].
|
|
86 |
|
|
87 |
^ super setupSmalltalkFromArguments:argv
|
350
|
88 |
! !
|
|
89 |
|
|
90 |
!RunUnitTestsStart class methodsFor:'documentation'!
|
|
91 |
|
|
92 |
version
|
|
93 |
^ '$Header$'
|
|
94 |
!
|
|
95 |
|
|
96 |
version_CVS
|
|
97 |
^ '$Header$'
|
|
98 |
! !
|
|
99 |
|