stx_goodies_sunit.st
author Claus Gittinger <cg@exept.de>
Wed, 24 Oct 2012 20:22:40 +0200
changeset 476 700cd1a9964c
parent 457 ae823abf01c0
child 518 9af19c20c2d6
permissions -rw-r--r--
automatic checkIn
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     1
"{ Package: 'stx:goodies/sunit' }"
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     2
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     3
LibraryDefinition subclass:#stx_goodies_sunit
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     4
	instanceVariableNames:''
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     5
	classVariableNames:''
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     6
	poolDictionaries:''
173
6fe46bec2948 Category change
Stefan Vogel <sv@exept.de>
parents: 172
diff changeset
     7
	category:'* Projects & Packages *'
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     8
!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     9
245
49ef4f1295cd changed: #extensionsVersion_CVS
Claus Gittinger <cg@exept.de>
parents: 235
diff changeset
    10
!stx_goodies_sunit class methodsFor:'documentation'!
49ef4f1295cd changed: #extensionsVersion_CVS
Claus Gittinger <cg@exept.de>
parents: 235
diff changeset
    11
457
ae823abf01c0 comment
Claus Gittinger <cg@exept.de>
parents: 440
diff changeset
    12
documentation
ae823abf01c0 comment
Claus Gittinger <cg@exept.de>
parents: 440
diff changeset
    13
"
ae823abf01c0 comment
Claus Gittinger <cg@exept.de>
parents: 440
diff changeset
    14
    Build- and package information for creation of the st/x standard library: stx_goodies_sunit
ae823abf01c0 comment
Claus Gittinger <cg@exept.de>
parents: 440
diff changeset
    15
    This library contains the sunit test framework.
ae823abf01c0 comment
Claus Gittinger <cg@exept.de>
parents: 440
diff changeset
    16
"
245
49ef4f1295cd changed: #extensionsVersion_CVS
Claus Gittinger <cg@exept.de>
parents: 235
diff changeset
    17
! !
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    18
156
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    19
!stx_goodies_sunit class methodsFor:'description'!
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    20
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    21
excludedFromPreRequisites
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    22
    "list all packages which should be ignored in the automatic
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    23
     preRequisites scan. See #preRequisites for more."
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    24
156
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    25
    ^ #(
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    26
    )
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    27
!
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    28
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    29
preRequisites
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    30
    "list all required packages.
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    31
     This list can be maintained manually or (better) generated and
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    32
     updated by scanning the superclass hierarchies and looking for
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    33
     global variable accesses. (the browser has a menu function for that)
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    34
     Howevery, often too much is found, and you may want to explicitely
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    35
     exclude individual packages in the #excludedFromPrerequisites method."
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    36
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    37
    ^ #(
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    38
	#'stx:libbasic'    "Object - superclass of SimpleTestResourceB1 "
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    39
	#'stx:libview'    "Color - referenced by TestRunner>>displayNormalColorInProgress "
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    40
	#'stx:libview2'    "Model - superclass of TestRunner "
156
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    41
    )
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    42
! !
6a4aebabacbd automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 149
diff changeset
    43
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    44
!stx_goodies_sunit class methodsFor:'description - contents'!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    45
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    46
classNamesAndAttributes
213
f40a88c5ec53 changed: #classNamesAndAttributes
Claus Gittinger <cg@exept.de>
parents: 193
diff changeset
    47
    "lists the classes which are to be included in the project.
f40a88c5ec53 changed: #classNamesAndAttributes
Claus Gittinger <cg@exept.de>
parents: 193
diff changeset
    48
     Each entry in the list may be: a single class-name (symbol),
f40a88c5ec53 changed: #classNamesAndAttributes
Claus Gittinger <cg@exept.de>
parents: 193
diff changeset
    49
     or an array-literal consisting of class name and attributes.
f40a88c5ec53 changed: #classNamesAndAttributes
Claus Gittinger <cg@exept.de>
parents: 193
diff changeset
    50
     Attributes are: #autoload or #<os> where os is one of win32, unix,..."
f40a88c5ec53 changed: #classNamesAndAttributes
Claus Gittinger <cg@exept.de>
parents: 193
diff changeset
    51
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    52
    ^ #(
343
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    53
        "<className> or (<className> attributes...) in load order"
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    54
        (ExampleTestResource autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    55
        SUnitDelay
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    56
        SUnitNameResolver
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    57
        TestAsserter
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    58
        TestFailure
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    59
        TestResult
476
700cd1a9964c automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 457
diff changeset
    60
        TestResultReporter
343
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    61
        TestRunner
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    62
        TestSuite
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    63
        (TestSuitesCompoundScriptTest autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    64
        (TestSuitesHierarchyScriptTest autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    65
        (TestSuitesScriptTest autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    66
        TestSuitesScripter
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    67
        #'stx_goodies_sunit'
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    68
        ResumableTestFailure
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    69
        TestCase
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    70
        TestCaseWithArguments
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    71
        TestResource
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    72
        (ExampleSetTest autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    73
        (ResumableTestFailureTestCase autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    74
        (SUnitTest autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    75
        (SimpleTestResource autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    76
        (SimpleTestResourceTestCase autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    77
        (FailingTestResourceTestCase autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    78
        (ManyTestResourceTestCase autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    79
        (SimpleTestResourceA autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    80
        (SimpleTestResourceA1 autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    81
        (SimpleTestResourceA2 autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    82
        (SimpleTestResourceB autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    83
        (SimpleTestResourceB1 autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    84
        (SimpleTestResourceCircular autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    85
        (SimpleTestResourceCircular1 autoload)
ae5570567e27 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 255
diff changeset
    86
        (CircularTestResourceTestCase autoload)
349
1cd3a8910934 Refactored to use TestResultOutcome
vrany
parents: 343
diff changeset
    87
        TestCaseOutcome
368
4ab674c862a7 Regenerate build files
vrany
parents: 367
diff changeset
    88
        TestResultStX
408
vrany
parents: 404
diff changeset
    89
        TestResultForRunWithDebug
440
4a544fda4bc8 changed: #classNamesAndAttributes
vrany
parents: 427
diff changeset
    90
        (SUnitTests2 autoload)
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    91
    )
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    92
!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    93
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    94
extensionMethodNames
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    95
    "lists the extension methods which are to be included in the project.
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    96
     Entries are 2-element array literals, consisting of class-name and selector."
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
    97
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    98
    ^ #(
427
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
    99
        Block sunitEnsure:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   100
        Block sunitOn:do:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   101
        GenericException sunitAnnounce:toResult:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   102
        GenericException sunitExitWith:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   103
        Object sunitAddDependent:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   104
        Object sunitChanged:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   105
        Object sunitRemoveDependent:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   106
        String sunitAsSymbol
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   107
        String sunitMatch:
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   108
        String sunitSubStrings
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   109
        Symbol sunitAsClass
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   110
        'GenericException class' sunitSignalWith:
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   111
    )
427
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   112
24632c550c74 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   113
    "Modified: / 21-08-2011 / 17:27:56 / cg"
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   114
! !
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   115
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   116
!stx_goodies_sunit class methodsFor:'description - project information'!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   117
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   118
companyName
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   119
    "Return a companyname which will appear in <lib>.rc"
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   120
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   121
    ^ 'eXept Software AG'
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   122
!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   123
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   124
description
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   125
    "Return a description string which will appear in nt.def / bc.def"
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   126
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   127
    ^ 'Smalltalk/X Class library'
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   128
!
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   129
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   130
legalCopyright
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   131
    "Return a copyright string which will appear in <lib>.rc"
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   132
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   133
    ^ 'Copyright eXept Software AG 1998-2007'
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   134
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   135
    "Modified: / 08-11-2007 / 16:57:33 / cg"
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   136
! !
177
f46c94410480 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 176
diff changeset
   137
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   138
!stx_goodies_sunit class methodsFor:'description - svn'!
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   139
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   140
svnRevisionNr
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   141
    "Return a SVN revision number of myself.
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   142
     This number is updated after a commit"
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   143
349
1cd3a8910934 Refactored to use TestResultOutcome
vrany
parents: 343
diff changeset
   144
    ^ "$SVN-Revision:"'exported'"$"
235
d06056977c51 automatic checkIn
Stefan Vogel <sv@exept.de>
parents: 222
diff changeset
   145
! !
d06056977c51 automatic checkIn
Stefan Vogel <sv@exept.de>
parents: 222
diff changeset
   146
251
9c8dafcfbf66 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   147
!stx_goodies_sunit class methodsFor:'documentation'!
235
d06056977c51 automatic checkIn
Stefan Vogel <sv@exept.de>
parents: 222
diff changeset
   148
356
17065e3b6395 automatic checkIn
vrany
parents: 349
diff changeset
   149
version
476
700cd1a9964c automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 457
diff changeset
   150
    ^ '$Header: /cvs/stx/stx/goodies/sunit/stx_goodies_sunit.st,v 1.34 2012-10-24 18:22:40 cg Exp $'
356
17065e3b6395 automatic checkIn
vrany
parents: 349
diff changeset
   151
!
17065e3b6395 automatic checkIn
vrany
parents: 349
diff changeset
   152
235
d06056977c51 automatic checkIn
Stefan Vogel <sv@exept.de>
parents: 222
diff changeset
   153
version_CVS
476
700cd1a9964c automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 457
diff changeset
   154
    ^ '$Header: /cvs/stx/stx/goodies/sunit/stx_goodies_sunit.st,v 1.34 2012-10-24 18:22:40 cg Exp $'
251
9c8dafcfbf66 automatic checkIn
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   155
!
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   156
222
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   157
version_SVN
8e6f482297fa Jan's 4.1 version
Claus Gittinger <cg@exept.de>
parents: 219
diff changeset
   158
    ^ '§Id: stx_goodies_sunit.st 214 2011-03-14 12:22:21Z vranyj1 §'
149
4fe695222d0a initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
   159
! !