UNPKG

playwright-fluent

Version:
16 lines (15 loc) 653 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const tslib_1 = require("tslib"); const SUT = tslib_1.__importStar(require("../index")); const type_text_1 = require("../../type-text"); describe('clear text', () => { test('should return an error when browser has not been launched', async () => { // Given const page = undefined; // When // Then const expectedError = new Error('Cannot clear text because no browser has been launched'); await SUT.clearText(page, type_text_1.defaultTypeTextOptions).catch((error) => expect(error).toMatchObject(expectedError)); }); });