The Trunk: Tests-nice.454.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Tests-nice.454.mcz

commits-2
Nicolas Cellier uploaded a new version of Tests to project The Trunk:
http://source.squeak.org/trunk/Tests-nice.454.mcz

==================== Summary ====================

Name: Tests-nice.454
Author: nice
Time: 16 April 2021, 10:39:27.763501 pm
UUID: a798edc1-1f4c-dc40-a835-38af2973efb5
Ancestors: Tests-nice.453

Use SyntaxErrorNotification>>retryWithNewSource: rather than resume:

This better document the intention (rather than the implementation).

Note that resume: will no longer tryNewSourceIfAvailable, it will just act as super, that is return its argument to the sender of signal.

=============== Diff against Tests-nice.453 ===============

Item was changed:
  ----- Method: CompilerSyntaxErrorNotifyingTest>>testResumeEarlySyntaxError (in category 'tests') -----
  testResumeEarlySyntaxError
 
  | result |
  result := [Compiler evaluate: '''''''']
  on: SyntaxErrorNotification
+ do: [:ex | ex retryWithNewSource: ''''''''''].
- do: [:ex | ex resume: ''''''''''].
  self assert: '''' equals: result!

Item was changed:
  ----- Method: CompilerSyntaxErrorNotifyingTest>>testResumeLateSyntaxError (in category 'tests') -----
  testResumeLateSyntaxError
 
  | result |
  result := [Compiler evaluate: '6*:7']
  on: SyntaxErrorNotification
+ do: [:ex | ex retryWithNewSource: '6*7'].
- do: [:ex | ex resume: '6*7'].
  self assert: 42 equals: result!