|
1 | 1 | /* eslint-disable max-statements */ |
2 | | -import fs from 'fs'; |
3 | | -import path from 'path'; |
| 2 | +const fs = require('fs'); |
| 3 | +const path = require('path'); |
4 | 4 |
|
5 | | -import { pass, fail, skip } from '@tunnckocore/create-jest-runner'; |
6 | | -import { isMonorepo } from '@tunnckocore/utils'; |
| 5 | +const { pass, fail, skip } = require('@tunnckocore/create-jest-runner'); |
| 6 | +const { isMonorepo } = require('@tunnckocore/utils'); |
7 | 7 |
|
8 | | -import cosmiconfig from 'cosmiconfig'; |
9 | | -import docks from './docks'; |
| 8 | +const cosmiconfig = require('cosmiconfig'); |
| 9 | +const docks = require('./docks'); |
10 | 10 |
|
11 | 11 | const jestRunnerConfig = cosmiconfig('jest-runner'); |
12 | 12 | const jestRunnerDocks = cosmiconfig('docks'); |
13 | 13 |
|
14 | | -export default async function jetRunnerDocs({ testPath, config }) { |
| 14 | +module.exports = async function jestRunnerDocs({ testPath, config }) { |
15 | 15 | const start = new Date(); |
16 | 16 | const conf = await tryLoadConfig(testPath, start); |
17 | 17 | if (conf.hasError) return conf.error; |
@@ -100,7 +100,7 @@ export default async function jetRunnerDocs({ testPath, config }) { |
100 | 100 | title: 'Docks', |
101 | 101 | }, |
102 | 102 | }); |
103 | | -} |
| 103 | +}; |
104 | 104 |
|
105 | 105 | async function tryLoadConfig(testPath, start) { |
106 | 106 | return tryCatch(testPath, start, () => { |
|
0 commit comments