diff options
Diffstat (limited to 'bench/tests/10000-transform.js')
-rw-r--r-- | bench/tests/10000-transform.js | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/bench/tests/10000-transform.js b/bench/tests/10000-transform.js index 0fcc162..9e22d09 100644 --- a/bench/tests/10000-transform.js +++ b/bench/tests/10000-transform.js @@ -1,4 +1,4 @@ -SVG.bench.describe('Transform 1000000 rects', function(bench) { +SVG.bench.describe('Transform 1000000 rects', function (bench) { let parameters = { translate: [20, 30], origin: [100, 100], @@ -6,27 +6,24 @@ SVG.bench.describe('Transform 1000000 rects', function(bench) { skew: [10, 30], scale: 0.5 } - - let matrixLike = {a:2, b:3, c:1, d:2, e:49, f:100} + + let matrixLike = { a: 2, b: 3, c: 1, d: 2, e: 49, f: 100 } let matrix = new SVG.Matrix(matrixLike) - + let worker = new SVG.Matrix() - bench.test('with parameters', function() { - for (var i = 0; i < 1000000; i++) - worker.transform(parameters) + bench.test('with parameters', function () { + for (var i = 0; i < 1000000; i++) worker.transform(parameters) }) - + worker = new SVG.Matrix() - bench.test('with matrix like', function() { + bench.test('with matrix like', function () { for (var i = 0; i < 1000000; i++) { worker.transform(matrixLike) } }) - + worker = new SVG.Matrix() - bench.test('with SVG.Matrix', function() { - for (var i = 0; i < 1000000; i++) - worker.transform(matrix) + bench.test('with SVG.Matrix', function () { + for (var i = 0; i < 1000000; i++) worker.transform(matrix) }) }) - |