preRunMessage.js 953 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. 'use strict';
  2. Object.defineProperty(exports, '__esModule', {
  3. value: true
  4. });
  5. exports.print = print;
  6. exports.remove = remove;
  7. function _chalk() {
  8. const data = _interopRequireDefault(require('chalk'));
  9. _chalk = function () {
  10. return data;
  11. };
  12. return data;
  13. }
  14. var _clearLine = _interopRequireDefault(require('./clearLine'));
  15. var _isInteractive = _interopRequireDefault(require('./isInteractive'));
  16. function _interopRequireDefault(obj) {
  17. return obj && obj.__esModule ? obj : {default: obj};
  18. }
  19. /**
  20. * Copyright (c) Meta Platforms, Inc. and affiliates.
  21. *
  22. * This source code is licensed under the MIT license found in the
  23. * LICENSE file in the root directory of this source tree.
  24. */
  25. function print(stream) {
  26. if (_isInteractive.default) {
  27. stream.write(
  28. _chalk().default.bold.dim('Determining test suites to run...')
  29. );
  30. }
  31. }
  32. function remove(stream) {
  33. if (_isInteractive.default) {
  34. (0, _clearLine.default)(stream);
  35. }
  36. }