Fix #1263: Fix page generation for AsciiDoc

This commit is contained in:
Samy Pessé
2016-05-04 09:30:09 +02:00
parent efb65a8413
commit 24d38e4fcf
2 changed files with 13 additions and 0 deletions
+4
View File
@@ -43,6 +43,10 @@ Parser.prototype.parseGlossary = function(content) {
Parser.prototype.preparePage = function(content) {
var page = this.get('page');
if (!page.prepare) {
return Promise(content);
}
return Promise(page.prepare(content));
};
+9
View File
@@ -12,6 +12,15 @@ describe('WebsiteGenerator', function() {
});
});
pit('should generate an index.html for AsciiDoc', function() {
return generateMock(WebsiteGenerator, {
'README.adoc': 'Hello World'
})
.then(function(folder) {
expect(folder).toHaveFile('index.html');
});
});
pit('should generate an HTML file for each articles', function() {
return generateMock(WebsiteGenerator, {
'README.md': 'Hello World',