From c594f75b4c59a5341741f012a4f2942a920bac8c Mon Sep 17 00:00:00 2001 From: Vojta Jina Date: Mon, 2 Jan 2012 20:50:17 -0800 Subject: refactor: remove old JSTD assertions So that we can run the tests even without JSTD :-D --- test/testabilityPatch.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'test/testabilityPatch.js') diff --git a/test/testabilityPatch.js b/test/testabilityPatch.js index 8150a0a3..b4d11f3a 100644 --- a/test/testabilityPatch.js +++ b/test/testabilityPatch.js @@ -174,12 +174,14 @@ function isCssVisible(node) { } function assertHidden(node) { - assertFalse("Node should be hidden but vas visible: " + - angular.module.ngMock.dump(node), isCssVisible(node)); + if (isCssVisible(node)) { + throw new Error('Node should be hidden but was visible: ' + angular.module.ngMock.dump(node)); + } } function assertVisible(node) { - assertTrue("Node should be visible but vas hidden: " + - angular.module.ngMock.dump(node), isCssVisible(node)); + if (!isCssVisible(node)) { + throw new Error('Node should be visible but was hidden: ' + angular.module.ngMock.dump(node)); + } } -- cgit v1.2.3