We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f27955 commit 09f0bbbCopy full SHA for 09f0bbb
test/regression/generateRegressionTests.ts
@@ -22,13 +22,14 @@ while (matched = componentExtractor.exec(taggedForRegression)) {
22
const regressionTest = async (t: TestContext, config: IConfig, component: string) => {
23
const snappit = new Snappit(config);
24
const driver = await snappit.start();
25
-
26
await util.go(driver, component);
+
27
for (const e of await driver.findElements(By.css(util.selectors.visreg))) {
28
const sectionName = await e.getAttribute("data-visreg");
29
t.log(` ${sectionName}:`);
30
await util.snapshot(t, e);
31
t.log(" ✔ DOM Snapshot");
32
+ await driver.executeScript("window.scroll(0, 0);");
33
await snappit.snap(`{browserName}/${sectionName}`, e as WebElement);
34
t.log(" ✔ Image Snapshot");
35
}
0 commit comments