Skip to content

Commit

Permalink
remove example
Browse files Browse the repository at this point in the history
  • Loading branch information
UziTech committed May 4, 2019
1 parent 3ef3285 commit 2881fc9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 0 additions & 1 deletion test/helpers/load.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ function loadFiles (dir) {
const content = fm(fs.readFileSync(absFile, 'utf8'));
specs = [{
section: name,
example: 1,
markdown: content.body,
html: fs.readFileSync(absFile.replace(/[^.]+$/, 'html'), 'utf8'),
options: content.attributes
Expand Down
4 changes: 3 additions & 1 deletion test/specs/run-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ function runSpecs (title, dir, showCompletionTable, options) {
describe(section, () => {
specs[section].specs.forEach((spec) => {
spec.options = Object.assign({}, options, (spec.options || {}));
(spec.only ? fit : it)('should ' + (spec.shouldFail ? 'fail' : 'pass') + ' example ' + spec.example, () => {
const example = (spec.example ? ' example ' + spec.example : '');
const passFail = (spec.shouldFail ? 'fail' : 'pass');
(spec.only ? fit : it)('should ' + passFail + example, () => {
const before = process.hrtime();
if (spec.shouldFail) {
expect(spec).not.toRender(spec.html);
Expand Down

0 comments on commit 2881fc9

Please sign in to comment.