From d03dd051957ba937d78e62d9af025fca18d9dddd Mon Sep 17 00:00:00 2001 From: Jonathan Puckey Date: Sat, 21 May 2011 12:48:43 +0200 Subject: [PATCH] Tests: compareItems: compare item#matrix if present. --- test/lib/helpers.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/lib/helpers.js b/test/lib/helpers.js index 09ced436..6a365994 100644 --- a/test/lib/helpers.js +++ b/test/lib/helpers.js @@ -135,6 +135,14 @@ function compareItems(item, item2) { equals(item._matrix.toString(), item2._matrix.toString(), 'item._matrix.toString() == item2._matrix.toString()'); } + + if (item.matrix) { + equals(function() { + return item.matrix != item2.matrix; + }, true); + equals(item.matrix.toString(), item2.matrix.toString(), + 'item.matrix.toString() == item2.matrix.toString()'); + } if (item2.segments) { equals(item.segments.toString(), item2.segments.toString(),