Andreas Raab uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-ar.436.mcz
==================== Summary ====================
Name: Kernel-ar.436
Author: ar
Time: 29 March 2010, 9:02:14.348 pm
UUID: d85068dc-e213-1149-81df-1f71ed09846c
Ancestors: Kernel-ar.435
Fix failing traits condenseChanges test. Since we do not share compiled methods, moving *all* trait methods (instead of just 'local' ones) is CORRECT behavior.
=============== Diff against Kernel-ar.435 ===============
Item was changed:
----- Method: ClassDescription>>moveChangesTo: (in category 'fileIn/Out') -----
moveChangesTo: newFile
"Used in the process of condensing changes, this message requests that
the source code of all methods of the receiver that have been changed
should be moved to newFile."
| changes |
changes := self methodDict keys select: [:sel |
+ (self compiledMethodAt: sel) fileIndex > 1].
- (self compiledMethodAt: sel) fileIndex > 1 and: [
- (self includesLocalSelector: sel) or: [
- (self compiledMethodAt: sel) sendsToSuper]]].
self
fileOutChangedMessages: changes
on: newFile
moveSource: true
toFile: 2!
Andreas Raab uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-ar.436.mcz
==================== Summary ====================
Name: Kernel-ar.436
Author: ar
Time: 29 March 2010, 9:02:14.348 pm
UUID: d85068dc-e213-1149-81df-1f71ed09846c
Ancestors: Kernel-ar.435
Fix failing traits condenseChanges test. Since we do not share compiled methods, moving *all* trait methods (instead of just 'local' ones) is CORRECT behavior.
=============== Diff against Kernel-ar.435 ===============
Item was changed:
----- Method: ClassDescription>>moveChangesTo: (in category 'fileIn/Out') -----
moveChangesTo: newFile
"Used in the process of condensing changes, this message requests that
the source code of all methods of the receiver that have been changed
should be moved to newFile."
| changes |
changes := self methodDict keys select: [:sel |
+ (self compiledMethodAt: sel) fileIndex > 1].
- (self compiledMethodAt: sel) fileIndex > 1 and: [
- (self includesLocalSelector: sel) or: [
- (self compiledMethodAt: sel) sendsToSuper]]].
self
fileOutChangedMessages: changes
on: newFile
moveSource: true
toFile: 2!
Andreas Raab uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-ar.436.mcz
==================== Summary ====================
Name: Kernel-ar.436
Author: ar
Time: 29 March 2010, 9:02:14.348 pm
UUID: d85068dc-e213-1149-81df-1f71ed09846c
Ancestors: Kernel-ar.435
Fix failing traits condenseChanges test. Since we do not share compiled methods, moving *all* trait methods (instead of just 'local' ones) is CORRECT behavior.
=============== Diff against Kernel-ar.435 ===============
Item was changed:
----- Method: ClassDescription>>moveChangesTo: (in category 'fileIn/Out') -----
moveChangesTo: newFile
"Used in the process of condensing changes, this message requests that
the source code of all methods of the receiver that have been changed
should be moved to newFile."
| changes |
changes := self methodDict keys select: [:sel |
+ (self compiledMethodAt: sel) fileIndex > 1].
- (self compiledMethodAt: sel) fileIndex > 1 and: [
- (self includesLocalSelector: sel) or: [
- (self compiledMethodAt: sel) sendsToSuper]]].
self
fileOutChangedMessages: changes
on: newFile
moveSource: true
toFile: 2!
Andreas Raab uploaded a new version of Tests to project The Trunk:
http://source.squeak.org/trunk/Tests-ar.66.mcz
==================== Summary ====================
Name: Tests-ar.66
Author: ar
Time: 29 March 2010, 9:00:35.581 pm
UUID: f10906a2-7e5d-0e41-a82e-031645e0d329
Ancestors: Tests-ul.65
Add two tests for FileStream behavior. One that I thought was broken (but is not) and one that is broken.
=============== Diff against Tests-ul.65 ===============
Item was added:
+ ----- Method: FileStreamTest>>testNextChunkOutOfBounds (in category 'as yet unclassified') -----
+ testNextChunkOutOfBounds
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testNextChunkOutOfBounds'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 999999; nextChunkText] valueWithin: 1 seconds onTimeout:[nil].
+ self assert: read = ''.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Item was added:
+ ----- Method: FileStreamTest>>testCachingNextChunkPut (in category 'as yet unclassified') -----
+ testCachingNextChunkPut
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testCachingNextChunkPut'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 0; nextChunkText] valueWithin: 1 seconds onTimeout:[''].
+ self assert: read = text.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Andreas Raab uploaded a new version of Tests to project The Trunk:
http://source.squeak.org/trunk/Tests-ar.66.mcz
==================== Summary ====================
Name: Tests-ar.66
Author: ar
Time: 29 March 2010, 9:00:35.581 pm
UUID: f10906a2-7e5d-0e41-a82e-031645e0d329
Ancestors: Tests-ul.65
Add two tests for FileStream behavior. One that I thought was broken (but is not) and one that is broken.
=============== Diff against Tests-ul.65 ===============
Item was added:
+ ----- Method: FileStreamTest>>testNextChunkOutOfBounds (in category 'as yet unclassified') -----
+ testNextChunkOutOfBounds
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testNextChunkOutOfBounds'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 999999; nextChunkText] valueWithin: 1 seconds onTimeout:[nil].
+ self assert: read = ''.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Item was added:
+ ----- Method: FileStreamTest>>testCachingNextChunkPut (in category 'as yet unclassified') -----
+ testCachingNextChunkPut
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testCachingNextChunkPut'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 0; nextChunkText] valueWithin: 1 seconds onTimeout:[''].
+ self assert: read = text.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Andreas Raab uploaded a new version of Tests to project The Trunk:
http://source.squeak.org/trunk/Tests-ar.66.mcz
==================== Summary ====================
Name: Tests-ar.66
Author: ar
Time: 29 March 2010, 9:00:35.581 pm
UUID: f10906a2-7e5d-0e41-a82e-031645e0d329
Ancestors: Tests-ul.65
Add two tests for FileStream behavior. One that I thought was broken (but is not) and one that is broken.
=============== Diff against Tests-ul.65 ===============
Item was added:
+ ----- Method: FileStreamTest>>testNextChunkOutOfBounds (in category 'as yet unclassified') -----
+ testNextChunkOutOfBounds
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testNextChunkOutOfBounds'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 999999; nextChunkText] valueWithin: 1 seconds onTimeout:[nil].
+ self assert: read = ''.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Item was added:
+ ----- Method: FileStreamTest>>testCachingNextChunkPut (in category 'as yet unclassified') -----
+ testCachingNextChunkPut
+ "Ensure that nextChunkPut:/nextChunk works properly on a caching file"
+ | file text read |
+ [file := FileStream forceNewFileNamed: 'testCachingNextChunkPut'.
+ text := 'this is a chunkful of text'.
+ file nextChunkPut: text.
+ read := [file position: 0; nextChunkText] valueWithin: 1 seconds onTimeout:[''].
+ self assert: read = text.
+ ] ensure:[file close. FileDirectory default deleteFileNamed: file name ifAbsent:[]].!
Andreas Raab uploaded a new version of TraitsTests to project The Trunk:
http://source.squeak.org/trunk/TraitsTests-ar.8.mcz
==================== Summary ====================
Name: TraitsTests-ar.8
Author: ar
Time: 29 March 2010, 8:58:51.65 pm
UUID: a365e4f0-6365-a346-83f4-764ff185d2b8
Ancestors: TraitsTests-ul.7
Add a test for the behavior of traits during condenseChanges.
=============== Diff against TraitsTests-ul.7 ===============
Item was added:
+ ----- Method: TraitFileOutTest>>testCondenseChanges (in category 'testing') -----
+ testCondenseChanges
+ "Tests moveChangesTo: in the face of aliases and other trait manipulations"
+ | file classOrTrait originals copy |
+ file := FileStream forceNewFileNamed: 'TraitFileOutTest.changes'.
+ [originals := IdentityDictionary new.
+ #(t1 t2 t3 t4 t5 t6 c1 c2) do:[:clsName|
+ classOrTrait := self perform: clsName.
+ classOrTrait methodsDo:[:each|
+ originals at: each put: each getSourceFromFile.
+ ].
+ file setToEnd.
+ classOrTrait moveChangesTo: file.
+ originals keysAndValuesDo:[:method :source|
+ "we need the upfront assertion to avoid a current bug
+ in #nextChunk when using out of bounds indexes"
+ self assert: method filePosition < file size.
+ copy := file position: method filePosition; nextChunkText.
+ self assert: copy = source.
+ ].
+ ].
+ ] ensure:[
+ file close.
+ FileDirectory default deleteFileNamed: file name ifAbsent:[].
+ ].!
Andreas Raab uploaded a new version of TraitsTests to project The Trunk:
http://source.squeak.org/trunk/TraitsTests-ar.8.mcz
==================== Summary ====================
Name: TraitsTests-ar.8
Author: ar
Time: 29 March 2010, 8:58:51.65 pm
UUID: a365e4f0-6365-a346-83f4-764ff185d2b8
Ancestors: TraitsTests-ul.7
Add a test for the behavior of traits during condenseChanges.
=============== Diff against TraitsTests-ul.7 ===============
Item was added:
+ ----- Method: TraitFileOutTest>>testCondenseChanges (in category 'testing') -----
+ testCondenseChanges
+ "Tests moveChangesTo: in the face of aliases and other trait manipulations"
+ | file classOrTrait originals copy |
+ file := FileStream forceNewFileNamed: 'TraitFileOutTest.changes'.
+ [originals := IdentityDictionary new.
+ #(t1 t2 t3 t4 t5 t6 c1 c2) do:[:clsName|
+ classOrTrait := self perform: clsName.
+ classOrTrait methodsDo:[:each|
+ originals at: each put: each getSourceFromFile.
+ ].
+ file setToEnd.
+ classOrTrait moveChangesTo: file.
+ originals keysAndValuesDo:[:method :source|
+ "we need the upfront assertion to avoid a current bug
+ in #nextChunk when using out of bounds indexes"
+ self assert: method filePosition < file size.
+ copy := file position: method filePosition; nextChunkText.
+ self assert: copy = source.
+ ].
+ ].
+ ] ensure:[
+ file close.
+ FileDirectory default deleteFileNamed: file name ifAbsent:[].
+ ].!
Andreas Raab uploaded a new version of TraitsTests to project The Trunk:
http://source.squeak.org/trunk/TraitsTests-ar.8.mcz
==================== Summary ====================
Name: TraitsTests-ar.8
Author: ar
Time: 29 March 2010, 8:58:51.65 pm
UUID: a365e4f0-6365-a346-83f4-764ff185d2b8
Ancestors: TraitsTests-ul.7
Add a test for the behavior of traits during condenseChanges.
=============== Diff against TraitsTests-ul.7 ===============
Item was added:
+ ----- Method: TraitFileOutTest>>testCondenseChanges (in category 'testing') -----
+ testCondenseChanges
+ "Tests moveChangesTo: in the face of aliases and other trait manipulations"
+ | file classOrTrait originals copy |
+ file := FileStream forceNewFileNamed: 'TraitFileOutTest.changes'.
+ [originals := IdentityDictionary new.
+ #(t1 t2 t3 t4 t5 t6 c1 c2) do:[:clsName|
+ classOrTrait := self perform: clsName.
+ classOrTrait methodsDo:[:each|
+ originals at: each put: each getSourceFromFile.
+ ].
+ file setToEnd.
+ classOrTrait moveChangesTo: file.
+ originals keysAndValuesDo:[:method :source|
+ "we need the upfront assertion to avoid a current bug
+ in #nextChunk when using out of bounds indexes"
+ self assert: method filePosition < file size.
+ copy := file position: method filePosition; nextChunkText.
+ self assert: copy = source.
+ ].
+ ].
+ ] ensure:[
+ file close.
+ FileDirectory default deleteFileNamed: file name ifAbsent:[].
+ ].!