Skip to content

Commit

Permalink
Fixed the tests for this version
Browse files Browse the repository at this point in the history
  • Loading branch information
Noel Bastubbe committed Jun 13, 2022
1 parent a20d07e commit c9ea600
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ testOnlyPlaysAnimationInsideStartEndTime
positionProperty
positionX: 555;
positionY: 555;
frame: (propertyStartEnd endTime)*2; "out of bounds"
frame: (propertyStartEnd startTime) - 1; "out of bounds"
addKeyframe.
animations := positionProperty createAnimationSequenceWithStartEnd: propertyStartEnd.
self assert: animations size = 2.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ testShowMessageKeyframeOutOfBounds
propertyStartEnd := self animationsEditorInstance propertyStartEnd.
positionProperty positionX: 555;
positionY: 555;
frame: propertyStartEnd endTime + 1000; "out of bounds"
frame: propertyStartEnd startTime - 1; "out of bounds"
addKeyframe.
positionProperty createAnimationSequenceWithStartEnd: propertyStartEnd.
self assert: self animationsEditorInstance informationBarText = positionProperty messageKeyframeOutOfBounds.
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
"testHasSubProperties" : "MH 8/1/2021 18:37",
"testInstanceCreation" : "DM 8/4/2020 13:47",
"testMessageNotEnoughKeyframes" : "MH 8/1/2021 18:38",
"testOnlyPlaysAnimationInsideStartEndTime" : "MH 8/1/2021 18:38",
"testOnlyPlaysAnimationInsideStartEndTime" : "Noel Bastubbe 6/13/2022 18:01",
"testPlayAnimationWithStartEnd" : "MH 8/1/2021 18:38",
"testShowMessageKeyframeOutOfBounds" : "MH 8/1/2021 18:38",
"testShowMessageKeyframeOutOfBounds" : "Noel Bastubbe 6/13/2022 18:05",
"testShowMessageSelectAnimatedProperty" : "CL 8/2/2021 09:05",
"testTargetValuesIsSorted" : "MH 8/1/2021 18:38" } }
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ testAddKeyframeToRightPosition
| keyframeCenter keyframeBar keyframeBarPosition addedKeyframeMorph |

keyframeBar := (self positionTrack submorphs at: (self secondLastOn: self positionTrack)).
keyframeBarPosition := keyframeBar bounds origin x @ keyframeBar bounds origin y.
keyframeBarPosition := keyframeBar position.

self createKeyframeWith: self animationPosition on: self middleOfAnimationTime.

addedKeyframeMorph := self positionTrack submorphs first.
keyframeCenter := self calculateKeyframeCenterOn: addedKeyframeMorph.
keyframeCenter := addedKeyframeMorph center.

self assert: (keyframeBar width / 2) @ (keyframeBar height / 2) + keyframeBarPosition = keyframeCenter.
self assert: ((keyframeBar width / 2) @ (keyframeBar height / 2) + keyframeBarPosition) truncated = keyframeCenter.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"setUp" : "NB 8/1/2021 15:20",
"startFrame" : "MH 8/1/2021 18:42",
"tearDown" : "NB 8/1/2021 12:38",
"testAddKeyframeToRightPosition" : "NB 8/1/2021 15:22",
"testAddKeyframeToRightPosition" : "Noel Bastubbe 6/13/2022 19:27",
"testDistanceBetweenKeyframes" : "mjs 8/1/2021 16:45",
"timeline" : "MH 8/1/2021 18:43",
"timeline:" : "MH 8/1/2021 18:43" } }

0 comments on commit c9ea600

Please sign in to comment.