The Trunk: KernelTests-ul.386.mcz

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

The Trunk: KernelTests-ul.386.mcz

commits-2
Levente Uzonyi uploaded a new version of KernelTests to project The Trunk:
http://source.squeak.org/trunk/KernelTests-ul.386.mcz

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

Name: KernelTests-ul.386
Author: ul
Time: 12 September 2020, 1:49:16.062715 pm
UUID: 7c7b8abb-7226-47e6-929e-b220b49cd714
Ancestors: KernelTests-ct.385

- added a test for Context >> #copyTo:

=============== Diff against KernelTests-ct.385 ===============

Item was added:
+ ----- Method: MethodContextTest>>testCopyTo (in category 'tests') -----
+ testCopyTo
+
+ | context depth targetSender |
+ context := thisContext.
+ depth := 1.
+ targetSender := context.
+ [ (targetSender := targetSender sender) isNil ] whileFalse: [
+ | original copy |
+ original := context.
+ copy := context copyTo: targetSender.
+ 1 to: depth do: [ :index |
+ index = 1 ifFalse: [
+ "Since we're copying thisContext, the pc and stackPtr may be different for the current frame."
+ self
+ assert: original pc equals: copy pc;
+ assert: original stackPtr equals: copy stackPtr ].
+ self
+ deny: original == copy;
+ assert: original method equals: copy method;
+ assert: original closure equals: copy closure;
+ assert: original receiver equals: copy receiver.
+ original := original sender.
+ copy := copy sender ].
+ self
+ assert: copy isNil;
+ assert: original == targetSender.
+ depth := depth + 1 ]!


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: KernelTests-ul.386.mcz

Christoph Thiede