Skip to content

Commit

Permalink
removed obsolete tests
Browse files Browse the repository at this point in the history
  • Loading branch information
asturur committed Dec 29, 2022
1 parent 64b4358 commit f031bb8
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 32 deletions.
16 changes: 0 additions & 16 deletions test/unit/canvas.js
Original file line number Diff line number Diff line change
Expand Up @@ -1334,22 +1334,6 @@
assert.equal(rect.getCenterPoint().x, upperCanvasEl.width / 2, 'object\'s "left" property should correspond to canvas element\'s center');
});

QUnit.test('straightenObject', function(assert) {
assert.ok(typeof canvas.straightenObject === 'function');
var rect = makeRect({ angle: 10 });
canvas.add(rect);
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 0, 'angle should be coerced to 0 (from 10)');

rect.rotate('60');
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 90, 'angle should be coerced to 90 (from 60)');

rect.rotate('100');
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 90, 'angle should be coerced to 90 (from 100)');
});

QUnit.test('toJSON', function(assert) {
assert.ok(typeof canvas.toJSON === 'function');
assert.equal(JSON.stringify(canvas.toJSON()), EMPTY_JSON);
Expand Down
16 changes: 0 additions & 16 deletions test/unit/canvas_static.js
Original file line number Diff line number Diff line change
Expand Up @@ -794,22 +794,6 @@
canvas.viewportTransform = [1, 0, 0, 1, 0, 0];
});

QUnit.test('straightenObject', function(assert) {
assert.ok(typeof canvas.straightenObject === 'function');
var rect = makeRect({ angle: 10 });
canvas.add(rect);
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 0, 'angle should be coerced to 0 (from 10)');

rect.rotate('60');
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 90, 'angle should be coerced to 90 (from 60)');

rect.rotate('100');
canvas.straightenObject(rect);
assert.equal(rect.get('angle'), 90, 'angle should be coerced to 90 (from 100)');
});

QUnit.test('toSVG', function(assert) {
assert.ok(typeof canvas.toSVG === 'function');
canvas.clear();
Expand Down

0 comments on commit f031bb8

Please sign in to comment.