Skip to content

Commit

Permalink
Merge pull request #4230 from guillep/fix/allocationTests
Browse files Browse the repository at this point in the history
Fix allocation tests
  • Loading branch information
tesonep committed Aug 8, 2019
2 parents 8f2aca0 + f3b4a25 commit 88e29ed
Showing 1 changed file with 29 additions and 2 deletions.
31 changes: 29 additions & 2 deletions src/Kernel-Tests/AllocationTest.class.st
Expand Up @@ -8,10 +8,25 @@ Class {
}

{ #category : #testing }
AllocationTest >> testOneGigAllocation [
AllocationTest >> testOneGBAllocation [
"Documentating a weird bug in the allocator"

| sz array failed |
failed := false.
sz := 1024*1024*1024.
array := [ByteArray new: sz] on: OutOfMemory do: [:ex| failed := true].
self assert: (failed or:[array size = sz]).

]

{ #category : #testing }
AllocationTest >> testOneGWordAllocation [
"Documentating a weird bug in the allocator"

| sz array failed |
"This takes too much time to run"
self timeLimit: 1 minute.

failed := false.
sz := 1024*1024*1024.
array := [Array new: sz] on: OutOfMemory do: [:ex| failed := true].
Expand All @@ -20,7 +35,19 @@ AllocationTest >> testOneGigAllocation [
]

{ #category : #testing }
AllocationTest >> testOneMegAllocation [
AllocationTest >> testOneMBAllocation [
"Documentating a weird bug in the allocator"

| sz array failed |
failed := false.
sz := 1024*1024.
array := [ByteArray new: sz] on: OutOfMemory do: [:ex| failed := true].
self assert: (failed or:[array size = sz]).

]

{ #category : #testing }
AllocationTest >> testOneMWordAllocation [
"Documentating a weird bug in the allocator"

| sz array failed |
Expand Down

0 comments on commit 88e29ed

Please sign in to comment.