test/test_keyframe.rb in tracksperanto-2.8.0 vs test/test_keyframe.rb in tracksperanto-2.8.1
- old
+ new
@@ -11,9 +11,15 @@
assert_equal 0, keyframe.frame
assert_equal 10.3, keyframe.abs_x
assert_equal 12.5, keyframe.abs_y
end
+ def test_sorts_on_frame
+ kf = Tracksperanto::Keyframe.new(:frame => 4, :abs_x => 10, :abs_y => 12.0)
+ kf2 = Tracksperanto::Keyframe.new(:frame => 2, :abs_x => 10, :abs_y => 12.0)
+ assert_equal [kf2, kf], [kf, kf2].sort
+ end
+
def test_inspect
kf = Tracksperanto::Keyframe.new(:frame => 0, :abs_x => 10, :abs_y => 12.0)
assert_equal "#< 10.0x12.0 @0 ~0.00) >", kf.inspect
end
\ No newline at end of file