Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 8173382

Browse files
chore(docs): remove excess indentation from code blocks
dgeni-packages 0.10.0-rc.5 has a fix for this problem, so this commit updates to that version. Adds a new e2e test to prove this is fixed. Closes #8963
1 parent 5524439 commit 8173382

File tree

2 files changed

+15
-38
lines changed

2 files changed

+15
-38
lines changed

Diff for: docs/app/e2e/api-docs/api-pages.scenario.js

+10
Original file line numberDiff line numberDiff line change
@@ -37,5 +37,15 @@ describe("doc.angularjs.org", function() {
3737
var code = element.all(by.css('tt')).first();
3838
expect(code.getText()).toContain('guest!!!');
3939
});
40+
41+
it("should trim indentation from code blocks", function() {
42+
browser.get('index-debug.html#!/api/ng/type/$rootScope.Scope');
43+
44+
var codeBlocks = element.all(by.css('pre > code.lang-js'));
45+
codeBlocks.each(function(codeBlock) {
46+
var firstSpan = codeBlock.all(by.css('span')).first();
47+
expect(firstSpan.getText()).not.toMatch(/^\W+$/);
48+
});
49+
});
4050
});
4151
});

Diff for: npm-shrinkwrap.json

+5-38
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)