1 | 'use strict';
|
2 |
|
3 | Object.defineProperty(exports, '__esModule', {
|
4 | value: true
|
5 | });
|
6 | exports.default = getNoTestFoundRelatedToChangedFiles;
|
7 | function _chalk() {
|
8 | const data = _interopRequireDefault(require('chalk'));
|
9 | _chalk = function () {
|
10 | return data;
|
11 | };
|
12 | return data;
|
13 | }
|
14 | function _jestUtil() {
|
15 | const data = require('jest-util');
|
16 | _jestUtil = function () {
|
17 | return data;
|
18 | };
|
19 | return data;
|
20 | }
|
21 | function _interopRequireDefault(obj) {
|
22 | return obj && obj.__esModule ? obj : {default: obj};
|
23 | }
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 |
|
30 |
|
31 | function getNoTestFoundRelatedToChangedFiles(globalConfig) {
|
32 | const ref = globalConfig.changedSince
|
33 | ? `"${globalConfig.changedSince}"`
|
34 | : 'last commit';
|
35 | let msg = _chalk().default.bold(
|
36 | `No tests found related to files changed since ${ref}.`
|
37 | );
|
38 | if (_jestUtil().isInteractive) {
|
39 | msg += _chalk().default.dim(
|
40 | `\n${
|
41 | globalConfig.watch
|
42 | ? 'Press `a` to run all tests, or run Jest with `--watchAll`.'
|
43 | : 'Run Jest without `-o` or with `--all` to run all tests.'
|
44 | }`
|
45 | );
|
46 | }
|
47 | return msg;
|
48 | }
|