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