feat: add normalizeWhiteSpace flag to toHaveValue
This commit is contained in:
parent
e43c309877
commit
f9dd5357b6
|
|
@ -355,7 +355,7 @@ export function toHaveValue(
|
||||||
options?: { timeout?: number },
|
options?: { timeout?: number },
|
||||||
) {
|
) {
|
||||||
return toMatchText.call(this, 'toHaveValue', locator, 'Locator', async (isNot, timeout) => {
|
return toMatchText.call(this, 'toHaveValue', locator, 'Locator', async (isNot, timeout) => {
|
||||||
const expectedText = serializeExpectedTextValues([expected]);
|
const expectedText = serializeExpectedTextValues([expected], { normalizeWhiteSpace: true });
|
||||||
return await locator._expect('to.have.value', { expectedText, isNot, timeout });
|
return await locator._expect('to.have.value', { expectedText, isNot, timeout });
|
||||||
}, expected, options);
|
}, expected, options);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue