Reverted back change from `assert: x equals: y` to assert: (x = u).
authorJan Vrany <jan.vrany@fit.cvut.cz>
Sat, 01 Nov 2014 00:12:10 +0000
changeset 402 1d7503124bc8
parent 401 538267cab6ec
child 403 7063d523b064
Reverted back change from `assert: x equals: y` to assert: (x = u). Actually, even Smalltalk/X SUnit has assert:equals:
analyzer/tests/PPAnalyzerTest.st
analyzer/tests/PPRewriterTest.st
analyzer/tests/PPSearcherTest.st
--- a/analyzer/tests/PPAnalyzerTest.st	Thu Oct 30 23:52:47 2014 +0000
+++ b/analyzer/tests/PPAnalyzerTest.st	Sat Nov 01 00:12:10 2014 +0000
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "{ Package: 'stx:goodies/petitparser/analyzer/tests' }"
 
 PPAbstractParserTest subclass:#PPAnalyzerTest
@@ -19,7 +17,7 @@
 !PPAnalyzerTest methodsFor:'accessing'!
 
 grammarA
-	"Güting, Erwig, Übersetzerbau, Springer (p.63)"
+	"Gting, Erwig, bersetzerbau, Springer (p.63)"
 
 	| grammar |
 	grammar := Dictionary new.
@@ -65,24 +63,24 @@
 	| grammar |
 	grammar := PPUnresolvedParser new.
 	grammar def: (grammar , $+ asParser , grammar) / $1 asParser.
-	^ grammar
+	^grammar
 !
 
 grammarD
-        "A highly ambiguous grammar from: Saichaitanya Jampana. Exploring the problem of ambiguity in context-free grammars. Master’s thesis, Oklahoma State University, July 2005."
+	"A highly ambiguous grammar from: Saichaitanya Jampana. Exploring the problem of ambiguity in context-free grammars. Master's thesis, Oklahoma State University, July 2005."
 
-        | grammar |
-        grammar := Dictionary new.
-        #(S A a B b)                    do: [ :each | grammar at: each put: (PPUnresolvedParser named: each) ].
+	| grammar |
+	grammar := Dictionary new.
+	#(S A a B b)			do: [ :each | grammar at: each put: (PPUnresolvedParser named: each) ].
 
-        (grammar at: #a)                def: $a asParser.
-        (grammar at: #b)                def: $b asParser.
-
-        (grammar at: #S)                def: (grammar at: #A) , (grammar at: #B) / (grammar at: #a).
-        (grammar at: #A)                def: (grammar at: #S) , (grammar at: #B) / (grammar at: #b).
-        (grammar at: #B)                def: (grammar at: #B) , (grammar at: #A) / (grammar at: #a).
-
-        ^ grammar
+	(grammar at: #a)		def: $a asParser.
+	(grammar at: #b)		def: $b asParser.
+		
+	(grammar at: #S)		def: (grammar at: #A) , (grammar at: #B) / (grammar at: #a).
+	(grammar at: #A)		def: (grammar at: #S) , (grammar at: #B) / (grammar at: #b).
+	(grammar at: #B)		def: (grammar at: #B) , (grammar at: #A) / (grammar at: #a).
+		
+	^ grammar
 !
 
 grammarE
@@ -98,15 +96,15 @@
 
 testAllNamedParsers
 	| p1 p2 p3 |
-	p1 := (#digit asParser name: 'a').
+	p1 := #digit asParser name: 'a'.
 	p2 := (#digit asParser name: 'b') star.
 	p3 := (#digit asParser name: 'c') token end.
-	self assert: p1 allNamedParsers size = 1.
-	self assert: p1 allNamedParsers first name = 'a'.
-	self assert: p2 allNamedParsers size = 1.
-	self assert: p2 allNamedParsers first name = 'b'.
-	self assert: p3 allNamedParsers size = 1.
-	self assert: p3 allNamedParsers first name = 'c'
+	self assert: p1 allNamedParsers size equals: 1.
+	self assert: p1 allNamedParsers first name equals: 'a'.
+	self assert: p2 allNamedParsers size equals: 1.
+	self assert: p2 allNamedParsers first name equals: 'b'.
+	self assert: p3 allNamedParsers size equals: 1.
+	self assert: p3 allNamedParsers first name equals: 'c'
 !
 
 testAllParsers
@@ -115,20 +113,20 @@
 	p2 := p1 ==> #asUppercase.
 	p3 := PPUnresolvedParser new.
 	p3 def: p2 / p3.
-	self assert: p1 allParsers size = 1.
-	self assert: p2 allParsers size = 2.
-	self assert: p3 allParsers size = 3
+	self assert: p1 allParsers size equals: 1.
+	self assert: p2 allParsers size equals: 2.
+	self assert: p3 allParsers size equals: 3
 !
 
 testInnerChildren
 	| p1 p2 p3 |
-	p1 := (#digit asParser name: 'a').
-	p2 := (#digit asParser star name: 'b').
+	p1 := #digit asParser name: 'a'.
+	p2 := #digit asParser star name: 'b'.
 	p3 := (#digit asParser name: 'c') token star end.
 	self assert: p1 innerChildren isEmpty.
-	self assert: p2 innerChildren size = 1.
+	self assert: p2 innerChildren size equals: 1.
 	self assert: (p2 innerChildren allSatisfy: [ :each | each name isNil ]).
-	self assert: p3 innerChildren size = 2.
+	self assert: p3 innerChildren size equals: 2.
 	self assert: (p3 innerChildren allSatisfy: [ :each | each name isNil ])
 !
 
@@ -163,17 +161,17 @@
 
 testNamedChildren
 	| p1 p2 p3 p4 |
-	p1 := (#digit asParser name: 'a').
+	p1 := #digit asParser name: 'a'.
 	p2 := (#digit asParser name: 'b') star.
 	p3 := (#digit asParser name: 'c') token end.
 	p4 := ((#digit asParser name: 'c') token name: 'd') end.
 	self assert: p1 namedChildren isEmpty.
-	self assert: p2 namedChildren size = 1.
-	self assert: p2 namedChildren first name = 'b'.
-	self assert: p3 namedChildren size = 1.
-	self assert: p3 namedChildren first name = 'c'.
-	self assert: p4 namedChildren size = 1.
-	self assert: p4 namedChildren first name = 'd'
+	self assert: p2 namedChildren size equals: 1.
+	self assert: p2 namedChildren first name equals: 'b'.
+	self assert: p3 namedChildren size equals: 1.
+	self assert: p3 namedChildren first name equals: 'c'.
+	self assert: p4 namedChildren size equals: 1.
+	self assert: p4 namedChildren first name equals: 'd'
 ! !
 
 !PPAnalyzerTest methodsFor:'testing-cycleset'!
@@ -190,26 +188,23 @@
 	| grammar cycleSet |
 	grammar := self grammarC.
 	cycleSet := grammar cycleSet.
-	self assert: (cycleSet size = 2).
+	self assert: cycleSet size equals: 2.
 	self assert: (cycleSet includes: grammar)
 !
 
 testCycleSetGrammarD
 	| grammar cycleSet |
 	grammar := self grammarD.
-	
 	cycleSet := (grammar at: #S) cycleSet.
-	self assert: (cycleSet size = 4).
+	self assert: cycleSet size equals: 4.
 	self assert: (cycleSet includes: (grammar at: #A)).
 	self assert: (cycleSet includes: (grammar at: #S)).
-	
 	cycleSet := (grammar at: #A) cycleSet.
-	self assert: (cycleSet size = 4).
+	self assert: cycleSet size equals: 4.
 	self assert: (cycleSet includes: (grammar at: #A)).
 	self assert: (cycleSet includes: (grammar at: #S)).
-
 	cycleSet := (grammar at: #B) cycleSet.
-	self assert: (cycleSet size = 2).
+	self assert: cycleSet size equals: 2.
 	self assert: (cycleSet includes: (grammar at: #B))
 !
 
@@ -217,7 +212,7 @@
 	| grammar cycleSet |
 	grammar := self grammarE.
 	cycleSet := grammar cycleSet.
-	self assert: (cycleSet size = 1).
+	self assert: cycleSet size equals: 1.
 	self assert: (cycleSet includes: grammar)
 !
 
@@ -226,14 +221,13 @@
 	parser := PPUnresolvedParser new.
 	parser def: parser / $a asParser.
 	cycleSet := parser cycleSet.
-	self assert: (cycleSet size = 1).
+	self assert: cycleSet size equals: 1.
 	self assert: (cycleSet includes: parser).
-	
 	parser := PPUnresolvedParser new.
 	parser def: $a asParser / parser.
 	cycleSet := parser cycleSet.
-	self assert: (cycleSet size = 1).
-	self assert: (cycleSet includes: parser).
+	self assert: cycleSet size equals: 1.
+	self assert: (cycleSet includes: parser)
 !
 
 testCycleSetInSequence
@@ -241,15 +235,13 @@
 	parser := PPUnresolvedParser new.
 	parser def: parser , $a asParser.
 	cycleSet := parser cycleSet.
-	self assert: (cycleSet size = 1).
+	self assert: cycleSet size equals: 1.
 	self assert: (cycleSet includes: parser).
-	
 	parser := PPUnresolvedParser new.
 	parser def: nil asParser , parser.
 	cycleSet := parser cycleSet.
-	self assert: (cycleSet size = 1).
+	self assert: cycleSet size equals: 1.
 	self assert: (cycleSet includes: parser).
-	
 	parser := PPUnresolvedParser new.
 	parser def: $a asParser , parser.
 	cycleSet := parser cycleSet.
--- a/analyzer/tests/PPRewriterTest.st	Thu Oct 30 23:52:47 2014 +0000
+++ b/analyzer/tests/PPRewriterTest.st	Sat Nov 01 00:12:10 2014 +0000
@@ -22,131 +22,103 @@
 	before := PPListPattern any.
 	between := PPListPattern any.
 	after := PPListPattern any.
-	rewriter
-		replace: before / duplicate / between / duplicate / after
-		with: before / duplicate / between / after.
-	
+	rewriter replace: before / duplicate / between / duplicate / after with: before / duplicate / between / after.
 	result := rewriter execute: $a asParser / $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children size = 1.
-	self assert: result children first literal = $a.
-	
+	self assert: result children size equals: 1.
+	self assert: result children first literal equals: $a.
 	result := rewriter execute: $b asParser / $a asParser / $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children size = 2.
-	self assert: result children first literal = $b.
-	self assert: result children last literal = $a.
-	
+	self assert: result children size equals: 2.
+	self assert: result children first literal equals: $b.
+	self assert: result children last literal equals: $a.
 	result := rewriter execute: $a asParser / $b asParser / $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children size = 2.
-	self assert: result children first literal = $a.
-	self assert: result children last literal = $b.
-	
+	self assert: result children size equals: 2.
+	self assert: result children first literal equals: $a.
+	self assert: result children last literal equals: $b.
 	result := rewriter execute: $a asParser / $a asParser / $b asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children size = 2.
-	self assert: result children first literal = $a.
-	self assert: result children last literal = $b	
+	self assert: result children size equals: 2.
+	self assert: result children first literal equals: $a.
+	self assert: result children last literal equals: $b
 !
 
 testPatternRemoval
 	| pattern result |
 	pattern := PPPattern class: PPLiteralObjectParser.
-	rewriter
-		replace: pattern / pattern
-		with: pattern.
-	
+	rewriter replace: pattern / pattern with: pattern.
 	result := rewriter execute: $a asParser / $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result class = PPLiteralObjectParser.
-	self assert: result literal = $a.
-	
+	self assert: result class equals: PPLiteralObjectParser.
+	self assert: result literal equals: $a.
 	result := rewriter execute: $a asParser / $a asParser / $a asParser.
 	self deny: rewriter hasChanged.
-	self assert: result class = PPChoiceParser.
-	self assert: result children size = 3
+	self assert: result class equals: PPChoiceParser.
+	self assert: result children size equals: 3
 !
 
 testPatternReplacement
 	| pattern result |
 	pattern := PPPattern class: PPLiteralObjectParser.
-	rewriter
-		replace: pattern
-		with: pattern , pattern.
-	
+	rewriter replace: pattern with: pattern , pattern.
 	result := rewriter execute: $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result class = PPSequenceParser.
-	self assert: result children first literal = $a.
-	self assert: result children last literal = $a.
-	
+	self assert: result class equals: PPSequenceParser.
+	self assert: result children first literal equals: $a.
+	self assert: result children last literal equals: $a.
 	result := rewriter execute: #any asParser.
 	self deny: rewriter hasChanged.
-	self assert: result class = PPPredicateObjectParser
+	self assert: result class equals: PPPredicateObjectParser
 !
 
 testReplaceLiteral
 	| result |
-	rewriter
-		replace: $a asParser 
-		with: $b asParser.
-	
+	rewriter replace: $a asParser with: $b asParser.
 	result := rewriter execute: $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result literal = $b.
-	
+	self assert: result literal equals: $b.
 	result := rewriter execute: $c asParser.
 	self deny: rewriter hasChanged.
-	self assert: result literal = $c.
-	
+	self assert: result literal equals: $c.
 	result := rewriter execute: $a asParser , $b asParser , $c asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children size = 3.
-	self assert: result children first literal = $b.
-	self assert: result children last literal = $c
+	self assert: result children size equals: 3.
+	self assert: result children first literal equals: $b.
+	self assert: result children last literal equals: $c
 !
 
 testSwapTwoPattern
 	| first second result |
 	first := PPPattern any.
 	second := PPPattern any.
-	rewriter
-		replace: first , second
-		with: second , first.
-	
+	rewriter replace: first , second with: second , first.
 	result := rewriter execute: $a asParser , $b asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children first literal = $b.
-	self assert: result children last literal = $a.
-	
+	self assert: result children first literal equals: $b.
+	self assert: result children last literal equals: $a.
 	result := rewriter execute: $a asParser / $b asParser.
 	self deny: rewriter hasChanged.
-	self assert: result children first literal = $a.
-	self assert: result children last literal = $b
+	self assert: result children first literal equals: $a.
+	self assert: result children last literal equals: $b
 !
 
 testWrapLiteral
 	| result |
-	rewriter
-		replace: $a asParser
-		withValueFrom: [ :parser | parser token ].
-	
+	rewriter replace: $a asParser withValueFrom: [ :parser | parser token ].
 	result := rewriter execute: $a asParser.
 	self assert: rewriter hasChanged.
-	self assert: result class = PPTokenParser.
-	self assert: result children first literal = $a.
-	
+	self assert: result class equals: PPTokenParser.
+	self assert: result children first literal equals: $a.
 	result := rewriter execute: $c asParser.
 	self deny: rewriter hasChanged.
-	self assert: result literal = $c.
-	
+	self assert: result literal equals: $c.
 	result := rewriter execute: $a asParser , $b asParser.
 	self assert: rewriter hasChanged.
-	self assert: result children first class = PPTokenParser.
-	self assert: result children first children first literal = $a.
-	self assert: result children last class = PPLiteralObjectParser.
-	self assert: result children last literal = $b
+	self assert: result children first class equals: PPTokenParser.
+	self assert: result children first children first literal equals: $a.
+	self assert: result children last class equals: PPLiteralObjectParser.
+	self assert: result children last literal equals: $b
 ! !
 
 !PPRewriterTest class methodsFor:'documentation'!
--- a/analyzer/tests/PPSearcherTest.st	Thu Oct 30 23:52:47 2014 +0000
+++ b/analyzer/tests/PPSearcherTest.st	Sat Nov 01 00:12:10 2014 +0000
@@ -20,146 +20,112 @@
 	| result |
 	searcher
 		matches: PPPattern any
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher
-		execute: ($a asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
-	
-	result := searcher
-		execute: ($a asParser star)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 2.
-	
-	result := searcher
-		execute: ($a asParser , $b asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 3
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
+	result := searcher execute: $a asParser star initialAnswer: OrderedCollection new.
+	self assert: result size equals: 2.
+	result := searcher execute: $a asParser , $b asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 3
 !
 
 testClassPattern
 	| result |
-	searcher 
+	searcher
 		matches: (PPPattern class: PPLiteralObjectParser)
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher
-		execute: ($a asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
 	self assert: (result allSatisfy: [ :each | each class = PPLiteralObjectParser ]).
-	
-	result := searcher
-		execute: ('abc' asParser)
-		initialAnswer: OrderedCollection new.
+	result := searcher execute: 'abc' asParser initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: (#any asParser)
-		initialAnswer: OrderedCollection new.
+	result := searcher execute: #any asParser initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: ($a asParser / #any asParser , $b asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 2.
+	result := searcher execute: $a asParser / #any asParser , $b asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 2.
 	self assert: (result allSatisfy: [ :each | each class = PPLiteralObjectParser ])
 !
 
 testKindPattern
 	| result |
-	searcher 
+	searcher
 		matches: (PPPattern kind: PPLiteralParser)
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher
-		execute: ($a asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
 	self assert: (result allSatisfy: [ :each | each class = PPLiteralObjectParser ]).
-	
-	result := searcher
-		execute: ('abc' asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
+	result := searcher execute: 'abc' asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
 	self assert: (result allSatisfy: [ :each | each class = PPLiteralSequenceParser ]).
-	
-	result := searcher
-		execute: (#any asParser)
-		initialAnswer: OrderedCollection new.
+	result := searcher execute: #any asParser initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: ($a asParser / #any asParser , $b asParser)
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 2.
+	result := searcher execute: $a asParser / #any asParser , $b asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 2.
 	self assert: (result allSatisfy: [ :each | each class = PPLiteralObjectParser ])
 !
 
 testMatchesAny
 	| result |
 	searcher
-		matchesAnyOf: (Array 
-			with: $a asParser
-			with: $b asParser)
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher
-		execute: $a asParser , $b asParser , $c asParser
-		initialAnswer: OrderedCollection new.
-	
-	self assert: result size = 2.
-	self assert: result first literal = $a.
-	self assert: result last literal = $b
+		matchesAnyOf: (Array with: $a asParser with: $b asParser)
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser , $b asParser , $c asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 2.
+	self assert: result first literal equals: $a.
+	self assert: result last literal equals: $b
 !
 
 testMultiplePattern
 	| result |
 	searcher
 		matches: $a asParser
-		do: [ :parser :answer | answer first add: parser. answer ].
+		do: [ :parser :answer | 
+			answer first add: parser.
+			answer ].
 	searcher
 		matches: PPPattern any
-		do: [ :parser :answer | answer second add: parser. answer ].
-
+		do: [ :parser :answer | 
+			answer second add: parser.
+			answer ].
 	result := searcher
 		execute: $a asParser , $a asParser , $b asParser
-		initialAnswer: (Array 
-			with: OrderedCollection new 
-			with: OrderedCollection new).
-	
-	self assert: result first size = 2.
-	self assert: result first first literal = $a.
-	self assert: result first last literal = $a.
-	
-	self assert: result last size = 2.
-	self assert: result last first class = PPSequenceParser.
-	self assert: result last last literal = $b
+		initialAnswer: (Array with: OrderedCollection new with: OrderedCollection new).
+	self assert: result first size equals: 2.
+	self assert: result first first literal equals: $a.
+	self assert: result first last literal equals: $a.
+	self assert: result last size equals: 2.
+	self assert: result last first class equals: PPSequenceParser.
+	self assert: result last last literal equals: $b
 !
 
 testNamePattern
 	| result |
-	searcher 
+	searcher
 		matches: (PPPattern name: 'foo')
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher 
-		execute: ($a asParser)
-		initialAnswer: OrderedCollection new.
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: ($a asParser name: 'foo')
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
-	self assert: result first name = 'foo'.
-	
-	result := searcher
-		execute: ($a asParser name: 'bar') , ($b asParser name: 'foo')
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
-	self assert: result first name = 'foo'
+	result := searcher execute: ($a asParser name: 'foo') initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
+	self assert: result first name equals: 'foo'.
+	result := searcher execute: ($a asParser name: 'bar') , ($b asParser name: 'foo') initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
+	self assert: result first name equals: 'foo'
 !
 
 testNewPattern
@@ -172,11 +138,8 @@
 	| recursive |
 	recursive := PPDelegateParser new.
 	recursive setParser: recursive.
-	searcher 
-		matches: recursive 
-		do: [ :parser :answer | parser ].
-	
-	self assert: (searcher execute: recursive) = recursive.
+	searcher matches: recursive do: [ :parser :answer | parser ].
+	self assert: (searcher execute: recursive) equals: recursive.
 	self assert: (searcher execute: $a asParser) isNil.
 	self assert: (searcher execute: $a asParser / $b asParser star) isNil
 !
@@ -185,27 +148,18 @@
 	| pattern result |
 	searcher
 		matches: (pattern := PPPattern any) , pattern
-		do: [ :parser :answer | answer add: parser; yourself ].
-
-	result := searcher
-		execute: ($a asParser , $b asParser)
-		initialAnswer: OrderedCollection new.
+		do: [ :parser :answer | 
+			answer
+				add: parser;
+				yourself ].
+	result := searcher execute: $a asParser , $b asParser initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: $a asParser , $a asParser
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1.
-	
-	result := searcher
-		execute: ($a asParser , ($a asParser , $b asParser))
-		initialAnswer: OrderedCollection new.
+	result := searcher execute: $a asParser , $a asParser initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1.
+	result := searcher execute: $a asParser , ($a asParser , $b asParser) initialAnswer: OrderedCollection new.
 	self assert: result isEmpty.
-	
-	result := searcher
-		execute: ($b asParser , ($a asParser , $a asParser))
-		initialAnswer: OrderedCollection new.
-	self assert: result size = 1
+	result := searcher execute: $b asParser , ($a asParser , $a asParser) initialAnswer: OrderedCollection new.
+	self assert: result size equals: 1
 ! !
 
 !PPSearcherTest methodsFor:'testing-copy'!
@@ -560,5 +514,10 @@
 
 version_CVS
     ^ '$Header: /cvs/stx/stx/goodies/petitparser/analyzer/tests/PPSearcherTest.st,v 1.1 2014-03-04 15:43:09 cg Exp $'
+!
+
+version_HG
+
+    ^ '$Changeset: <not expanded> $'
 ! !