aboutsummaryrefslogtreecommitdiffstats
path: root/test/ng/compileSpec.js
diff options
context:
space:
mode:
authorOren Avissar2013-04-22 21:00:15 -0700
committerPete Bacon Darwin2013-04-29 16:57:33 +0100
commitc3235db9ee89041f4c9c9b39fbf1a41ab866820c (patch)
treeec73af293da81cb47f289e5829cdd3c64a9f1068 /test/ng/compileSpec.js
parent738113bac88b549000d071059d1eea501e9c9db2 (diff)
downloadangular.js-c3235db9ee89041f4c9c9b39fbf1a41ab866820c.tar.bz2
test(browser/compile): fix calls to Jasmine fail()
The fail() function in Jasmine expects an Error object parameter. Also, there is no global alias for fail() so it must be accessed using `this.fail(new Error())`.
Diffstat (limited to 'test/ng/compileSpec.js')
-rwxr-xr-x[-rw-r--r--]test/ng/compileSpec.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/ng/compileSpec.js b/test/ng/compileSpec.js
index d24a9dac..50aa30ef 100644..100755
--- a/test/ng/compileSpec.js
+++ b/test/ng/compileSpec.js
@@ -540,8 +540,8 @@ describe('$compile', function() {
it('should prevent multiple templates per element', inject(function($compile) {
try {
- $compile('<div><span replace class="replace"></span></div>')
- fail();
+ $compile('<div><span replace class="replace"></span></div>');
+ this.fail(new Error('should have thrown Multiple directives error'));
} catch(e) {
expect(e.message).toMatch(/Multiple directives .* asking for template/);
}