mirror of
https://github.com/idanoo/GoScrobble
synced 2025-07-01 21:52:19 +00:00
19 lines
No EOL
605 B
JavaScript
19 lines
No EOL
605 B
JavaScript
"use strict";
|
|
|
|
Object.defineProperty(exports, "__esModule", {
|
|
value: true
|
|
});
|
|
exports.toBeEmpty = toBeEmpty;
|
|
|
|
var _utils = require("./utils");
|
|
|
|
function toBeEmpty(element) {
|
|
(0, _utils.deprecate)('toBeEmpty', 'Please use instead toBeEmptyDOMElement for finding empty nodes in the DOM.');
|
|
(0, _utils.checkHtmlElement)(element, toBeEmpty, this);
|
|
return {
|
|
pass: element.innerHTML === '',
|
|
message: () => {
|
|
return [this.utils.matcherHint(`${this.isNot ? '.not' : ''}.toBeEmpty`, 'element', ''), '', 'Received:', ` ${this.utils.printReceived(element.innerHTML)}`].join('\n');
|
|
}
|
|
};
|
|
} |