Skip to content

Commit 58b2cfa

Browse files
committed
chore: more test failures
1 parent 1e0fc4c commit 58b2cfa

File tree

2 files changed

+213
-154
lines changed

2 files changed

+213
-154
lines changed

src/lib/select/select.spec.ts

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1507,6 +1507,15 @@ describe('MatSelect', () => {
15071507
// Scroll the select into view
15081508
setScrollTop(1700);
15091509

1510+
// In the iOS simulator (BrowserStack & SauceLabs), adding the content to the
1511+
// body causes karma's iframe for the test to stretch to fit that content once we attempt to
1512+
// scroll the page. Setting width / height / maxWidth / maxHeight on the iframe does not
1513+
// successfully constrain its size. As such, skip assertions in environments where the
1514+
// window size has changed since the start of the test.
1515+
if (window.innerHeight > startingWindowHeight) {
1516+
return;
1517+
}
1518+
15101519
trigger.click();
15111520
fixture.detectChanges();
15121521

@@ -1526,6 +1535,15 @@ describe('MatSelect', () => {
15261535
// Scroll the select into view
15271536
setScrollTop(1700);
15281537

1538+
// In the iOS simulator (BrowserStack & SauceLabs), adding the content to the
1539+
// body causes karma's iframe for the test to stretch to fit that content once we attempt to
1540+
// scroll the page. Setting width / height / maxWidth / maxHeight on the iframe does not
1541+
// successfully constrain its size. As such, skip assertions in environments where the
1542+
// window size has changed since the start of the test.
1543+
if (window.innerHeight > startingWindowHeight) {
1544+
return;
1545+
}
1546+
15291547
trigger.click();
15301548
fixture.detectChanges();
15311549

@@ -1598,6 +1616,15 @@ describe('MatSelect', () => {
15981616
// Scroll the select so that it has insufficient space to open above the trigger
15991617
setScrollTop(1950);
16001618

1619+
// In the iOS simulator (BrowserStack & SauceLabs), adding the content to the
1620+
// body causes karma's iframe for the test to stretch to fit that content once we attempt to
1621+
// scroll the page. Setting width / height / maxWidth / maxHeight on the iframe does not
1622+
// successfully constrain its size. As such, skip assertions in environments where the
1623+
// window size has changed since the start of the test.
1624+
if (window.innerHeight > startingWindowHeight) {
1625+
return;
1626+
}
1627+
16011628
trigger.click();
16021629
fixture.detectChanges();
16031630

0 commit comments

Comments
 (0)