smalltalk
/
osmo-st-core
Archived
1
0
Fork 0

dispatcher: Really merge it, verify that install is called

This commit is contained in:
Holger Hans Peter Freyther 2014-07-27 11:11:40 +02:00
parent c5f53b7d64
commit 4ff8679b49
3 changed files with 6 additions and 2 deletions

View File

@ -23,7 +23,7 @@ Object subclass: Dispatcher [
Dispatcher class >> instance [
<category: 'singleton'>
^ Smalltalk at: #OsmoDispatcher ifAbsentPut: [Dispatcher new].
^ Smalltalk at: #OsmoDispatcher ifAbsent: [self install].
]
Dispatcher class >> new [

View File

@ -30,6 +30,10 @@ TestCase subclass: DispatcherTest [
OsmoDispatcher dispatchBlock: [sem signal].
self assert: sem signals = 1.
]
testSameDispatcher[
self assert: Dispatcher instance == Dispatcher instance
]
]
TestCase subclass: TimerSchedulerTest [

View File

@ -49,6 +49,6 @@ TimerScheduler extend [
Dispatcher class extend [
initialize [
^ self instance
self instance
]
]