Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent Opitz committed May 29, 2019
1 parent 327897c commit 5ddcad4
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
as yet unclassified
removeAllButtons

self buttons do: [:each | each abandon]
self buttons do: [:each | each abandon].
self buttons removeAll
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"initialize" : "VO 5/22/2019 16:45",
"model" : "VO 5/22/2019 18:06",
"model:" : "VO 5/22/2019 18:04",
"removeAllButtons" : "VO 5/22/2019 16:45",
"removeAllButtons" : "VO 5/29/2019 16:26",
"showButtons:" : "VO 5/22/2019 17:32",
"toolBuilder" : "VO 5/22/2019 17:58",
"toolBuilder:" : "VO 5/22/2019 16:55" } }
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
accessing
tool

^ self slideContainer model
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@
"submorphs" : "WoC 7/24/2018 17:55",
"tearDown" : "VO 5/15/2019 18:01",
"testAcceptDropImageFile" : "LM 7/25/2018 12:27",
"testTextFieldCreatedOnDoubleClick" : "WoC 7/25/2018 13:49" } }
"testTextFieldCreatedOnDoubleClick" : "WoC 7/25/2018 13:49",
"tool" : "VO 5/29/2019 16:18" } }
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
container tests
testAdvancedMenuBarHasAllTheButtons

| actionSelectorsWanted actionSelectorsGotten |
self click: MouseEvent redButton at: self morph center.
actionSelectorsWanted := self container menuBarItems reject: [:each | each at: #noButton ifAbsent: [false]].
actionSelectorsWanted := actionSelectorsWanted collect: [:each | each at: #action].
actionSelectorsGotten := self tool advancedMenuBar buttons collect: [:each | each actionSelector].
self assert: actionSelectorsWanted asSet equals: actionSelectorsGotten asSet.


Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
container tests
testAdvancedMenuBarHasNoButtonsAfterUnselect

self tool removeSelection.
self assert: self tool advancedMenuBar buttons isEmpty


Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
"defaultDragOffset" : "MK 7/25/2018 11:50",
"setUp" : "LM 7/25/2018 13:00",
"testAbandonMorphDeletesContainer" : "LM 7/25/2018 12:52",
"testAdvancedMenuBarHasAllTheButtons" : "VO 5/29/2019 16:21",
"testAdvancedMenuBarHasNoButtonsAfterUnselect" : "VO 5/29/2019 16:26",
"testColorDialog" : "VO 5/16/2019 16:27",
"testContainerResizingAllCorners" : "MK 7/25/2018 11:52",
"testContainerResizingCorner:" : "WoC 7/25/2018 12:18",
Expand Down

0 comments on commit 5ddcad4

Please sign in to comment.