RegressionTests__ProjectDefinitionTests.st
changeset 1447 2351db93aa5b
parent 1371 d2c150602389
child 1500 d406a10b2965
child 1884 ad279a6d791d
equal deleted inserted replaced
1446:c3b09cef9f87 1447:2351db93aa5b
     1 "{ Encoding: utf8 }"
     1 "{ Encoding: utf8 }"
     2 
     2 
     3 "{ Package: 'exept:regression' }"
     3 "{ Package: 'stx:goodies/regression' }"
     4 
     4 
     5 "{ NameSpace: RegressionTests }"
     5 "{ NameSpace: RegressionTests }"
     6 
     6 
     7 TestCase subclass:#ProjectDefinitionTests
     7 TestCase subclass:#ProjectDefinitionTests
     8 	instanceVariableNames:''
     8 	instanceVariableNames:''
    19 
    19 
    20     "Also, wipe out all mocks"
    20     "Also, wipe out all mocks"
    21     classes := OrderedCollection new.
    21     classes := OrderedCollection new.
    22     methods := OrderedCollection new.
    22     methods := OrderedCollection new.
    23     Smalltalk allClassesDo:[:cls|
    23     Smalltalk allClassesDo:[:cls|
    24         (cls package notNil and:[cls package startsWith:'exept:regression/testData']) ifTrue:[
    24 	(cls package notNil and:[cls package startsWith:'stx:goodies/regression/testData']) ifTrue:[
    25             classes add: cls
    25 	    classes add: cls
    26         ] ifFalse:[
    26 	] ifFalse:[
    27             cls methodsDo:[:m|(m package notNil and:[m package startsWith:'exept:regression/testData']) ifTrue:[methods add: m]].
    27 	    cls methodsDo:[:m|(m package notNil and:[m package startsWith:'stx:goodies/regression/testData']) ifTrue:[methods add: m]].
    28             cls class methodsDo:[:m|(m package notNil and:[m package startsWith:'exept:regression/testData']) ifTrue:[methods add: m]].
    28 	    cls class methodsDo:[:m|(m package notNil and:[m package startsWith:'stx:goodies/regression/testData']) ifTrue:[methods add: m]].
    29         ]
    29 	]
    30     ].
    30     ].
    31     Class withoutUpdatingChangesDo:[
    31     Class withoutUpdatingChangesDo:[
    32         classes do:[:cls|Smalltalk removeClass: cls].
    32 	classes do:[:cls|Smalltalk removeClass: cls].
    33         methods do:[:m|m mclass removeSelector: m selector]
    33 	methods do:[:m|m mclass removeSelector: m selector]
    34     ].
    34     ].
    35 
    35 
    36     "Created: / 22-03-2013 / 11:31:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
    36     "Created: / 22-03-2013 / 11:31:49 / Jan Vrany <jan.vrany@fit.cvut.cz>"
    37 ! !
    37 ! !
    38 
    38 
    96     Test of filein of a extension with non-ASCII/ISO8859-1 chars
    96     Test of filein of a extension with non-ASCII/ISO8859-1 chars
    97     "
    97     "
    98 
    98 
    99     Transcript showCR:'loading p1utf8 package...'.
    99     Transcript showCR:'loading p1utf8 package...'.
   100     [
   100     [
   101         Smalltalk loadPackage: 'exept:regression/testData/packages/p1utf8'.
   101 	Smalltalk loadPackage: 'stx:goodies/regression/testData/packages/p1utf8'.
   102     ] ifCurtailed:[
   102     ] ifCurtailed:[
   103         thisContext fullPrintAll
   103 	thisContext fullPrintAll
   104     ].    
   104     ].
   105     Transcript showCR:'done.'.
   105     Transcript showCR:'done.'.
   106 
   106 
   107     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) notNil.
   107     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) notNil.
   108     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) new zork size = 38.
   108     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) new zork size = 38.
   109     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) new zork = 'Příliš žluťoučký kůň úpěl ďábelské ódy'.
   109     self assert: (Smalltalk at:#ProjectDefinitionTestsP1UTF8Bar) new zork = 'Příliš žluťoučký kůň úpěl ďábelské ódy'.
   110 
   110 
   111     self assert: nil zork size = 38.
   111     self assert: nil zork size = 38.
   112     self assert: nil zork = 'Příliš žluťoučký kůň úpěl ďábelské ódy'.
   112     self assert: nil zork = 'Příliš žluťoučký kůň úpěl ďábelské ódy'.
   113 
   113 
   114     Transcript showCR:'test done.'.
   114     Transcript showCR:'test done.'.
   115     Smalltalk unloadPackage: 'exept:regression/testData/packages/p1utf8'.
   115     Smalltalk unloadPackage: 'stx:goodies/regression/testData/packages/p1utf8'.
   116 
   116 
   117     "Created: / 22-03-2013 / 11:44:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   117     "Created: / 22-03-2013 / 11:44:15 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   118 ! !
   118 ! !
   119 
   119 
   120 !ProjectDefinitionTests methodsFor:'tests-obsolete'!
   120 !ProjectDefinitionTests methodsFor:'tests-obsolete'!