diff options
| author | Igor Minar | 2013-07-01 17:23:24 -0700 |
|---|---|---|
| committer | Igor Minar | 2013-07-02 11:05:30 -0700 |
| commit | 4f0f2437712a5ae3e79780e2d6fa32b70abe1a52 (patch) | |
| tree | 7df06087f943728120c66052b23ffd8bb109e5cc /test/AngularSpec.js | |
| parent | 48eb297c1130fd08b22ba2bae032d3a5339c8615 (diff) | |
| download | angular.js-4f0f2437712a5ae3e79780e2d6fa32b70abe1a52.tar.bz2 | |
fix($injector): refactor module loading code and use minErr
Diffstat (limited to 'test/AngularSpec.js')
| -rw-r--r-- | test/AngularSpec.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/AngularSpec.js b/test/AngularSpec.js index 9686ffd6..8fda7a65 100644 --- a/test/AngularSpec.js +++ b/test/AngularSpec.js @@ -605,7 +605,9 @@ describe('angular', function() { expect(function() { angularInit(appElement, bootstrap); - }).toThrow("[$injector:nomod] Module 'doesntexist' is not available! You either misspelled the module name or forgot to load it."); + }).toThrowMatching( + /\[\$injector:modulerr] Failed to instantiate module doesntexist due to:\n.*\[\$injector:nomod] Module 'doesntexist' is not available! You either misspelled the module name or forgot to load it\./ + ); }); }); @@ -749,7 +751,8 @@ describe('angular', function() { expect(function() { angular.bootstrap(element, ['doesntexist']); - }).toThrow("[$injector:nomod] Module 'doesntexist' is not available! You either misspelled the module name or forgot to load it."); + }).toThrowMatching( + /\[\$injector:modulerr\] Failed to instantiate module doesntexist due to:\n.*\[\$injector:nomod\] Module 'doesntexist' is not available! You either misspelled the module name or forgot to load it\./); expect(element.html()).toBe('{{1+2}}'); dealoc(element); |
