react-native-navigation的迁移库

test-js.js 415B

123456789101112131415161718192021
  1. const exec = require('shell-utils').exec;
  2. const _ = require('lodash');
  3. const fix = _.includes(process.argv, '--fix') ? '--fix' : '';
  4. const dirs = [
  5. 'lib/src',
  6. 'integration',
  7. 'e2e',
  8. 'scripts',
  9. 'playground/src'
  10. ];
  11. run();
  12. function run() {
  13. const paths = _.chain(dirs).map((d) => `${d}/**/**/**/**/**/**/*`).join(' ').value();
  14. exec.execSync(`xo ${paths} ${fix}`);
  15. exec.execSync(`jest --coverage`);
  16. }