added very slow performance test

This commit is contained in:
David Poetzsch-Heffter 2024-01-18 15:36:53 +01:00
parent 95255984ad
commit 11b6aa2105
2 changed files with 3707 additions and 0 deletions

File diff suppressed because it is too large Load Diff

View File

@ -30,6 +30,7 @@ var globals = {
function runTests () {
var testMDFile = fs.readFileSync('test/performance.testfile.md', 'utf8');
var testMDFileBig = fs.readFileSync('test/performance.big.testfile.md', 'utf8');
new performance.Suite('Basic')
.setOption('cycles', 50)
.add('Simple "Hello World"', function () {
@ -42,6 +43,14 @@ function runTests () {
test: function (mdText) {
converter.makeHtml(mdText);
}
})
.add('performance.big.testfile.md', {
prepare: function () {
return testMDFileBig;
},
test: function (mdText) {
converter.makeHtml(mdText);
}
});
new performance.Suite('subParsers')
.setOption('cycles', 20)