Skip to content

Commit 86bb1fa

Browse files
committed
fix(jest-runner-docs): tweaks
Signed-off-by: Charlike Mike Reagent <opensource@tunnckocore.com>
1 parent 7339b22 commit 86bb1fa

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

packages/jest-runner-docs/src/runner.js

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -99,11 +99,8 @@ module.exports = async function jestRunnerDocs({ testPath, config }) {
9999
{ testPath, start },
100100
);
101101

102-
let outFile = outfile;
103-
104-
if (!outFile) outFile = docksConfig.outfile;
105-
if (outFile.hasError) return outFile.error;
106-
if (outFile.skip) return outFile.skip;
102+
if (outfile.hasError) return outfile.error;
103+
if (outfile.skip) return outfile.skip;
107104

108105
const postHook =
109106
typeof docksConfig.postHook === 'function'
@@ -116,18 +113,18 @@ module.exports = async function jestRunnerDocs({ testPath, config }) {
116113
pkgRoot,
117114
jestConfig: config,
118115
docksConfig,
119-
outFile,
120-
outfile: outFile,
116+
outfile,
117+
outFile: outfile,
121118
}),
122119
{ start, testPath },
123120
);
124-
if (res.hasError) return res.error;
121+
if (res && res.hasError) return res.error;
125122

126123
return pass({
127124
start,
128125
end: new Date(),
129126
test: {
130-
path: outFile,
127+
path: outfile,
131128
title: 'Docks',
132129
},
133130
});

0 commit comments

Comments
 (0)