deprecated.js 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. 'use strict';
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. var _chalk;
  6. function _load_chalk() {
  7. return _chalk = _interopRequireDefault(require('chalk'));
  8. }
  9. var _prettyFormat;
  10. function _load_prettyFormat() {
  11. return _prettyFormat = _interopRequireDefault(require('pretty-format'));
  12. }
  13. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  14. /**
  15. * Copyright (c) 2014-present, Facebook, Inc. All rights reserved.
  16. *
  17. * This source code is licensed under the MIT license found in the
  18. * LICENSE file in the root directory of this source tree.
  19. *
  20. *
  21. */
  22. const format = value => (0, (_prettyFormat || _load_prettyFormat()).default)(value, { min: true });
  23. exports.default = {
  24. mapCoverage: () => ` Option ${(_chalk || _load_chalk()).default.bold('"mapCoverage"')} has been removed, as it's no longer necessary.
  25. Please update your configuration.`,
  26. preprocessorIgnorePatterns: options => ` Option ${(_chalk || _load_chalk()).default.bold('"preprocessorIgnorePatterns"')} was replaced by ${(_chalk || _load_chalk()).default.bold('"transformIgnorePatterns"')}, which support multiple preprocessors.
  27. Jest now treats your current configuration as:
  28. {
  29. ${(_chalk || _load_chalk()).default.bold('"transformIgnorePatterns"')}: ${(_chalk || _load_chalk()).default.bold(format(options.preprocessorIgnorePatterns))}
  30. }
  31. Please update your configuration.`,
  32. scriptPreprocessor: options => ` Option ${(_chalk || _load_chalk()).default.bold('"scriptPreprocessor"')} was replaced by ${(_chalk || _load_chalk()).default.bold('"transform"')}, which support multiple preprocessors.
  33. Jest now treats your current configuration as:
  34. {
  35. ${(_chalk || _load_chalk()).default.bold('"transform"')}: ${(_chalk || _load_chalk()).default.bold(`{".*": ${format(options.scriptPreprocessor)}}`)}
  36. }
  37. Please update your configuration.`,
  38. testPathDirs: options => ` Option ${(_chalk || _load_chalk()).default.bold('"testPathDirs"')} was replaced by ${(_chalk || _load_chalk()).default.bold('"roots"')}.
  39. Jest now treats your current configuration as:
  40. {
  41. ${(_chalk || _load_chalk()).default.bold('"roots"')}: ${(_chalk || _load_chalk()).default.bold(format(options.testPathDirs))}
  42. }
  43. Please update your configuration.
  44. `
  45. };