mirror of
https://github.com/zhigang1992/angular.js.git
synced 2026-01-13 08:59:54 +08:00
chore(ngdocs): disable code prettification in e2e tests
code prettification is expensive and not needed for e2e tests, so I'm disabling it to speed up the e2e test suite. this is a temporary measure, see previous commit for more info.
This commit is contained in:
@@ -102,7 +102,12 @@ directive.prettyprint = ['reindentCode', function(reindentCode) {
|
||||
//ensure that angular won't compile {{ curly }} values
|
||||
html = html.replace(/\{\{/g, '<span>{{</span>')
|
||||
.replace(/\}\}/g, '<span>}}</span>');
|
||||
element.html(window.prettyPrintOne(reindentCode(html), undefined, true));
|
||||
if (window.RUNNING_IN_NG_TEST_RUNNER) {
|
||||
element.html(html);
|
||||
}
|
||||
else {
|
||||
element.html(window.prettyPrintOne(reindentCode(html), undefined, true));
|
||||
}
|
||||
}
|
||||
};
|
||||
}];
|
||||
|
||||
@@ -54,8 +54,8 @@
|
||||
addTag('script', {src: path('angular-animate.js') }, sync);
|
||||
addTag('script', {src: 'components/angular-bootstrap.js' }, sync);
|
||||
addTag('script', {src: 'components/angular-bootstrap-prettify.js' }, sync);
|
||||
addTag('script', {src: 'components/google-code-prettify.js' }, sync);
|
||||
if (!window.RUNNING_IN_NG_TEST_RUNNER) {
|
||||
addTag('script', {src: 'components/google-code-prettify.js' }, sync);
|
||||
addTag('script', {src: 'components/' + (debug ? 'lunr.js' : 'lunr.min.js') }, sync);
|
||||
}
|
||||
addTag('script', {src: 'components/marked.js' }, sync);
|
||||
|
||||
Reference in New Issue
Block a user