Skip to content

Commit

Permalink
test: replace usages of webkit-scrollbar with scrollbar-width (#11825)
Browse files Browse the repository at this point in the history
  • Loading branch information
whimboo committed Feb 2, 2024
1 parent 6514acc commit 197f005
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 77 deletions.
66 changes: 0 additions & 66 deletions test/TestExpectations.json
Original file line number Diff line number Diff line change
Expand Up @@ -3376,12 +3376,6 @@
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots ElementHandle.screenshot should capture full element when larger than viewport",
"platforms": ["win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots ElementHandle.screenshot should work for an element with an offset",
"platforms": ["darwin", "linux", "win32"],
Expand Down Expand Up @@ -3412,66 +3406,12 @@
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should clip rect",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["firefox", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should clip rect",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should return base64",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["firefox", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should return base64",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should take fullPage screenshots",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should take fullPage screenshots",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["firefox", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should take fullPage screenshots without captureBeyondViewport",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["firefox", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should take fullPage screenshots without captureBeyondViewport",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should work",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["firefox", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots Page.screenshot should work",
"platforms": ["darwin", "linux", "win32"],
"parameters": ["cdp", "firefox"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[stacktrace.spec] Stack trace should work for none error objects",
"platforms": ["darwin", "linux", "win32"],
Expand Down Expand Up @@ -3842,12 +3782,6 @@
"parameters": ["cdp", "chrome", "headful"],
"expectations": ["FAIL", "PASS"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots ElementHandle.screenshot should capture full element when larger than viewport",
"platforms": ["darwin", "win32"],
"parameters": ["firefox", "headless", "webDriverBiDi"],
"expectations": ["FAIL"]
},
{
"testIdPattern": "[screenshot.spec] Screenshots ElementHandle.screenshot should work for an element with an offset",
"platforms": ["darwin", "linux", "win32"],
Expand Down
7 changes: 4 additions & 3 deletions test/assets/frames/nested-frames.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<style>
:root {
scrollbar-width: none;
}

body {
display: flex;
}
Expand All @@ -7,9 +11,6 @@
flex-grow: 1;
flex-shrink: 1;
}
::-webkit-scrollbar{
display: none;
}
</style>
<script>
async function attachFrame(frameId, url) {
Expand Down
9 changes: 4 additions & 5 deletions test/assets/grid.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@

<style>

:root {
scrollbar-width: none;
}

body {
margin: 0;
padding: 0;
Expand All @@ -45,8 +49,3 @@
box-sizing: border-box;
border: 1px solid darkgray;
}

::-webkit-scrollbar {
display: none;
}
</style>
6 changes: 3 additions & 3 deletions test/src/screenshot.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -232,15 +232,15 @@ describe('Screenshots', function () {
await page.setContent(`
something above
<style>
:root {
scrollbar-width: none;
}
div.to-screenshot {
border: 1px solid blue;
width: 600px;
height: 600px;
margin-left: 50px;
}
::-webkit-scrollbar{
display: none;
}
</style>
<div class="to-screenshot"></div>
`);
Expand Down

0 comments on commit 197f005

Please sign in to comment.