You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
750 B

"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = debugShallow;
var _shallow = require("../shallow");
var _format = _interopRequireDefault(require("./format"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/**
* Log pretty-printed shallow test component instance
*/
function debugShallow(instance, message) {
const {
output
} = (0, _shallow.shallowInternal)(instance);
if (message) {
// eslint-disable-next-line no-console
console.log(`${message}\n\n`, (0, _format.default)(output));
} else {
// eslint-disable-next-line no-console
console.log((0, _format.default)(output));
}
}
//# sourceMappingURL=debugShallow.js.map