PHP Classes

File: public/js/tinymce/src/themes/mobile/src/test/js/atomic/smooth/SmoothAnimationTest.js

Recommend this page to a friend!
  Classes of Abed Nego Ragil Putra   GoLavaCMS   public/js/tinymce/src/themes/mobile/src/test/js/atomic/smooth/SmoothAnimationTest.js   Download  
File: public/js/tinymce/src/themes/mobile/src/test/js/atomic/smooth/SmoothAnimationTest.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: GoLavaCMS
Publish content on Web pages with SEO support
Author: By
Last change:
Date: 6 years ago
Size: 1,212 bytes
 

Contents

Class file image Download
test( 'Smooth Animation AdjustTest', [ 'global!assert', 'tinymce.themes.mobile.ios.smooth.SmoothAnimation' ], function (assert, SmoothAnimation) { var checkNone = function (label, value, destination, amount) { var actual = SmoothAnimation.adjust(value, destination, amount); assert.eq(true, actual.isNone(), 'Test: ' + label + '. Expected none but was: ' + actual.toString()); }; var check = function (label, expected, value, destination, amount) { var actual = SmoothAnimation.adjust(value, destination, amount); assert.eq(true, actual.is(expected), 'Test: ' + label + '. Expected some(' + expected + ') but was: ' + actual.toString()); }; checkNone( 'Already at target', 10, 10, 5 ); checkNone( 'Within target from below', 9, 10, 5 ); checkNone( 'Within target from above', 11, 10, 5 ); checkNone( '-Amount away from target', 8, 10, 2 ); checkNone( '+Amount away from target', 12, 10, 2 ); check( 'Far above target', 100, 200, 50, 100 ); check( 'Far below target', 100, 0, 250, 100 ); } );