@helpscout/cyan
Advanced tools
Comparing version 0.10.0 to 0.10.1
@@ -14,3 +14,3 @@ import cy from './cy'; | ||
export * from './timers'; | ||
export { getCSSFromDocument } from './utils/css.utils'; | ||
export { getDocumentCSS } from './utils/css.utils'; | ||
export default cy; |
@@ -15,3 +15,3 @@ "use strict"; | ||
promiseQueue: true, | ||
getCSSFromDocument: true | ||
getDocumentCSS: true | ||
}; | ||
@@ -66,6 +66,6 @@ Object.defineProperty(exports, "cy", { | ||
}); | ||
Object.defineProperty(exports, "getCSSFromDocument", { | ||
Object.defineProperty(exports, "getDocumentCSS", { | ||
enumerable: true, | ||
get: function get() { | ||
return _css.getCSSFromDocument; | ||
return _css.getDocumentCSS; | ||
} | ||
@@ -72,0 +72,0 @@ }); |
@@ -10,2 +10,4 @@ "use strict"; | ||
var _promises = require("./promises"); | ||
var useFakeTimers = function () { | ||
@@ -40,2 +42,3 @@ (0, _configuration.setConfigState)({ | ||
jest.runAllTimers(); | ||
(0, _promises.runAllPromises)(); | ||
}; | ||
@@ -42,0 +45,0 @@ |
@@ -76,3 +76,3 @@ import CyanInterface, { Selector, CySelector } from './Cyan.interface.types'; | ||
/** | ||
* Runs all immediates, ticks, and timers. | ||
* Runs all immediates, ticks, timers, and Mock Promises. | ||
* | ||
@@ -110,2 +110,16 @@ * @example | ||
/** | ||
* Runs only pending ticks and timers queued by Jest. | ||
* | ||
* @example | ||
* cy.runOnlyPendingTimers() | ||
*/ | ||
runOnlyPendingTimers(): void; | ||
/** | ||
* Runs all ticks and timers queued by Jest. | ||
* | ||
* @example | ||
* cy.runAllTimers() | ||
*/ | ||
runAllTimers(): void; | ||
/** | ||
* Mocks the global Promise. Ensures that all Promises process synchronously. | ||
@@ -112,0 +126,0 @@ * Promisees do not immediately invoke. They are added to a Mock Promise queue. |
{ | ||
"name": "@helpscout/cyan", | ||
"version": "0.10.0", | ||
"version": "0.10.1", | ||
"description": "Cypress-like Testing for React + JSDOM", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
176048
4149
117