author | Claus Gittinger <cg@exept.de> |
Tue, 08 May 2018 19:58:20 +0200 | |
changeset 1043 | aeecdb5610e4 |
parent 826 | 8886db76fa6b |
child 1121 | c5661215109c |
permissions | -rw-r--r-- |
22 | 1 |
"{ Package: 'stx:goodies/monticello/test' }" |
2 |
||
3 |
MCTestCase subclass:#MCScannerTest |
|
4 |
instanceVariableNames:'' |
|
5 |
classVariableNames:'' |
|
6 |
poolDictionaries:'' |
|
826
8886db76fa6b
Tests moved to category SCM-Monticello-Tests
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
147
diff
changeset
|
7 |
category:'SCM-Monticello-Tests' |
22 | 8 |
! |
9 |
||
10 |
||
11 |
!MCScannerTest methodsFor:'asserting'! |
|
12 |
||
13 |
assertScans: anArray |
|
147
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
14 |
Smalltalk isSmalltalkX ifTrue:[ |
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
15 |
self assert: (MCScanner scan: anArray storeString readStream) = anArray |
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
16 |
] ifFalse:[ |
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
17 |
self assert: (MCScanner scan: anArray printString readStream) = anArray |
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
18 |
] |
22 | 19 |
! ! |
20 |
||
21 |
!MCScannerTest methodsFor:'tests'! |
|
22 |
||
23 |
test1 |
|
24 |
self assertScans: #(a '23' (x)) |
|
25 |
! |
|
26 |
||
27 |
test2 |
|
28 |
self assertScans: 'it''s alive' |
|
29 |
! |
|
30 |
||
31 |
test3 |
|
32 |
self assert: (MCScanner scan: '(a #b c)' readStream) = #(a #b c) |
|
33 |
! |
|
34 |
||
35 |
test4 |
|
36 |
self assertScans: #(a '23' (x () ')''q' y12)). |
|
37 |
! |
|
38 |
||
39 |
test5 |
|
40 |
self assertScans: #((a) b) |
|
41 |
! |
|
42 |
||
43 |
test6 |
|
44 |
self should: [MCScanner scan: '(a b' readStream] raise: Error |
|
45 |
! ! |
|
46 |
||
47 |
!MCScannerTest class methodsFor:'documentation'! |
|
48 |
||
49 |
version |
|
826
8886db76fa6b
Tests moved to category SCM-Monticello-Tests
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
147
diff
changeset
|
50 |
^ '$Header: /cvs/stx/stx/goodies/monticello/test/MCScannerTest.st,v 1.3 2013-05-29 00:02:49 vrany Exp $' |
147
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
51 |
! |
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
52 |
|
2a935cef890e
more porting (but still unfinished)
Claus Gittinger <cg@exept.de>
parents:
22
diff
changeset
|
53 |
version_CVS |
826
8886db76fa6b
Tests moved to category SCM-Monticello-Tests
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
147
diff
changeset
|
54 |
^ '$Header: /cvs/stx/stx/goodies/monticello/test/MCScannerTest.st,v 1.3 2013-05-29 00:02:49 vrany Exp $' |
22 | 55 |
! ! |
826
8886db76fa6b
Tests moved to category SCM-Monticello-Tests
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
147
diff
changeset
|
56 |