diff options
| author | Igor Minar | 2013-04-03 14:36:57 -0700 |
|---|---|---|
| committer | Igor Minar | 2013-04-03 17:40:15 -0700 |
| commit | fec4ef38815340e8e5a6b65fd6c08f5c74e701d8 (patch) | |
| tree | 084b4797094099beba867eb6dda4c4c47c8c82b3 /src/bootstrap | |
| parent | ecdf119a76476f2a57105a3170be4075e43765c3 (diff) | |
| download | angular.js-fec4ef38815340e8e5a6b65fd6c08f5c74e701d8.tar.bz2 | |
feat(Scenario): autodisable animations when running e2e tests
animations cause the dom to contain elements that have been removed
from the model but are being animated out.
we could teach the e2e runner to wait for animations but that would
make all tests slower. it should be quite safe to just disable
animations automatically when the app is running via the e2e test
runner.
this change disables only css animations. we should make additional
change that disables js animations as well, but since we don't need
this right now I'm punting on it.
Diffstat (limited to 'src/bootstrap')
| -rw-r--r-- | src/bootstrap/bootstrap-prettify.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/bootstrap/bootstrap-prettify.js b/src/bootstrap/bootstrap-prettify.js index 026587a2..a9e61d4f 100644 --- a/src/bootstrap/bootstrap-prettify.js +++ b/src/bootstrap/bootstrap-prettify.js @@ -179,7 +179,8 @@ directive.ngEvalJavascript = ['getEmbeddedTemplate', function(getEmbeddedTemplat }]; -directive.ngEmbedApp = ['$templateCache', '$browser', '$rootScope', '$location', function($templateCache, $browser, docsRootScope, $location) { +directive.ngEmbedApp = ['$templateCache', '$browser', '$rootScope', '$location', '$sniffer', + function($templateCache, $browser, docsRootScope, $location, $sniffer) { return { terminal: true, link: function(scope, element, attrs) { @@ -189,6 +190,7 @@ directive.ngEmbedApp = ['$templateCache', '$browser', '$rootScope', '$location', $provide.value('$templateCache', $templateCache); $provide.value('$anchorScroll', angular.noop); $provide.value('$browser', $browser); + $provide.value('$sniffer', $sniffer); $provide.provider('$location', function() { this.$get = ['$rootScope', function($rootScope) { docsRootScope.$on('$locationChangeSuccess', function(event, oldUrl, newUrl) { @@ -223,6 +225,7 @@ directive.ngEmbedApp = ['$templateCache', '$browser', '$rootScope', '$location', event.preventDefault(); } }); + angular.bootstrap(element, modules); } }; |
