From 861bac1d2808b15abb867e761ded8144bf5f7e94 Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Wed, 31 Mar 2010 17:56:16 -0700 Subject: started to add services --- test/AngularTest.js | 44 -------------------------------------------- 1 file changed, 44 deletions(-) delete mode 100644 test/AngularTest.js (limited to 'test/AngularTest.js') diff --git a/test/AngularTest.js b/test/AngularTest.js deleted file mode 100644 index 8db723e5..00000000 --- a/test/AngularTest.js +++ /dev/null @@ -1,44 +0,0 @@ -AngularTest = TestCase('AngularTest'); - -UrlWatcherTest = TestCase('UrlWatcherTest'); - -UrlWatcherTest.prototype.testUrlWatcher = function () { - expectAsserts(2); - var location = {href:"http://server", hash:""}; - var watcher = new UrlWatcher(location); - watcher.delay = 1; - watcher.listener = function(url){ - assertEquals('http://getangular.test', url); - }; - watcher.setTimeout = function(fn, delay){ - assertEquals(1, delay); - location.href = "http://getangular.test"; - watcher.setTimeout = function(fn, delay) { - }; - fn(); - }; - watcher.watch(); -}; - -UrlWatcherTest.prototype.testItShouldFireOnUpdateEventWhenSpecialURLSet = function(){ - expectAsserts(2); - var location = {href:"http://server", hash:"#$iframe_notify=1234"}; - var watcher = new UrlWatcher(location); - angular.callbacks._iframe_notify_1234 = function () { - assertEquals("undefined", typeof angularCallbacks._iframe_notify_1234); - assertEquals("http://server2#", location.href); - }; - watcher.delay = 1; - watcher.expectedUrl = "http://server2"; - watcher.setTimeout = function(fn, delay){ - watcher.setTimeout = function(fn, delay) {}; - fn(); - }; - watcher.watch(); -}; - -FunctionTest = TestCase("FunctionTest"); - -FunctionTest.prototype.testEscapeHtml = function () { - assertEquals("<div>&</div>", escapeHtml('