-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DC MILL 0.2339 #388
DC MILL 0.2339 #388
Conversation
Fix unit tests
Update workflow
MWPW-135084 POC Visual Comparison Test
MWPW-136128: Added star-outline icon
Puru/mwpw 136133 Improved CLS score
Hello, I'm Franklin Bot and I will run some test suites that validate the page speed.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
eslint
test/e2e/frictionless/step-definitions/dc.steps.js|291 col 7| 'baseDir' is never reassigned. Use 'const' instead.
test/e2e/frictionless/step-definitions/dc.steps.js|293 col 9| Use object destructuring.
test/e2e/frictionless/step-definitions/dc.steps.js|296 col 51| Expected parentheses around arrow function argument.
test/e2e/frictionless/step-definitions/dc.steps.js|301 col 12| 'image' is never reassigned. Use 'const' instead.
test/e2e/frictionless/step-definitions/dc.steps.js|304 col 9| 'diffImage' is never reassigned. Use 'const' instead.
test/e2e/frictionless/step-definitions/dc.steps.js|311 col 5| Expected an error object to be thrown.
test/e2e/frictionless/step-definitions/dc.steps.js|315 col 40| Unnecessary escape character: ".
test/e2e/frictionless/step-definitions/dc.steps.js|315 col 58| Unexpected unnamed async function.
test/e2e/frictionless/step-definitions/dc.steps.js|341 col 30| Trailing spaces not allowed.
@@ -23,8 +23,10 @@ import { CompressPdfPage } from "../page-objects/compresspdf.page"; | |||
import { FrictionlessPage } from "../page-objects/frictionless.page"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <import/extensions> reported by reviewdog 🐶
Missing file extension "js" for "../page-objects/frictionless.page"
@@ -23,8 +23,10 @@ | |||
import { FrictionlessPage } from "../page-objects/frictionless.page"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -23,8 +23,10 @@ | |||
import { FrictionlessPage } from "../page-objects/frictionless.page"; | |||
import { cardinal } from "../support/cardinal"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <import/extensions> reported by reviewdog 🐶
Missing file extension "js" for "../support/cardinal"
@@ -23,8 +23,10 @@ | |||
import { FrictionlessPage } from "../page-objects/frictionless.page"; | |||
import { cardinal } from "../support/cardinal"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -23,8 +23,10 @@ | |||
import { FrictionlessPage } from "../page-objects/frictionless.page"; | |||
import { cardinal } from "../support/cardinal"; | |||
import { expect } from "@playwright/test"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <import/no-extraneous-dependencies> reported by reviewdog 🐶
'@playwright/test' should be listed in the project's dependencies. Run 'npm i -S @playwright/test' to add it
await this.page.closeSubMenu(index); | ||
await expect(this.page.fedsPopup).not.toBeVisible(); | ||
} | ||
}); | ||
|
||
/*** | ||
* This step is used to compare the current screenshots with the baseline | ||
* screenshots. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-trailing-spaces> reported by reviewdog 🐶
Trailing spaces not allowed.
* screenshots. | |
* screenshots. |
/*** | ||
* This step is used to compare the current screenshots with the baseline | ||
* screenshots. | ||
* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-trailing-spaces> reported by reviewdog 🐶
Trailing spaces not allowed.
* | |
* |
* screenshots. | ||
* | ||
* Baseline Folder: features/${feature-name}/${platform}/${browser} | ||
* Current Folder: ${report-dir}/screenshots/${feature-name}/${platform}/${browser} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-trailing-spaces> reported by reviewdog 🐶
Trailing spaces not allowed.
* Current Folder: ${report-dir}/screenshots/${feature-name}/${platform}/${browser} | |
* Current Folder: ${report-dir}/screenshots/${feature-name}/${platform}/${browser} |
* Baseline Folder: features/${feature-name}/${platform}/${browser} | ||
* Current Folder: ${report-dir}/screenshots/${feature-name}/${platform}/${browser} | ||
* Diff Image: ${report-dir}/${platform}_${browser}_${image-name}.png | ||
* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-trailing-spaces> reported by reviewdog 🐶
Trailing spaces not allowed.
* | |
* |
* Command line options: | ||
* --baseBrowser: Use a different browser to compare with the current browser | ||
*/ | ||
Then(/^I should see the same screenshots as baseline$/, async function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unexpected unnamed async function.
MWPW-136679 Changed width value in reading-width class
MWPW-136317 Dropzone enabled on L1 verbs (plus compress) except rotate
*/ | ||
Then(/^I should see the same screenshots as baseline$/, async function () { | ||
const comparator = getComparator('image/png'); | ||
let baseDir = this.gherkinDocument.uri.replace('.feature', ''); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prefer-const> reported by reviewdog 🐶
'baseDir' is never reassigned. Use 'const' instead.
let baseDir = this.gherkinDocument.uri.replace('.feature', ''); | |
const baseDir = this.gherkinDocument.uri.replace('.feature', ''); |
const comparator = getComparator('image/png'); | ||
let baseDir = this.gherkinDocument.uri.replace('.feature', ''); | ||
|
||
const profile = global.config.profile; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prefer-destructuring> reported by reviewdog 🐶
Use object destructuring.
const profile = global.config.profile; | |
const {profile} = global.config; |
const profile = global.config.profile; | ||
let outputDir = this.gherkinDocument.uri.split('/features/')[1].replace('.feature', ''); | ||
outputDir = `${profile.reportDir}/screenshots/${outputDir}/${os.platform()}/${profile.browser}`; | ||
const images = fs.readdirSync(outputDir).filter(x => x.endsWith('.png')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <arrow-parens> reported by reviewdog 🐶
Expected parentheses around arrow function argument.
const images = fs.readdirSync(outputDir).filter(x => x.endsWith('.png')); | |
const images = fs.readdirSync(outputDir).filter((x) => x.endsWith('.png')); |
const baseBrowser = profile.baseBrowser || profile.browser; | ||
|
||
const errors = []; | ||
for (let image of images) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prefer-const> reported by reviewdog 🐶
'image' is never reassigned. Use 'const' instead.
for (let image of images) { | |
for (const image of images) { |
for (let image of images) { | ||
const baseImage = fs.readFileSync(`${baseDir}/${os.platform()}/${baseBrowser}/${image}`); | ||
const currImage = fs.readFileSync(`${outputDir}/${image}`); | ||
let diffImage = comparator(baseImage, currImage); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prefer-const> reported by reviewdog 🐶
'diffImage' is never reassigned. Use 'const' instead.
let diffImage = comparator(baseImage, currImage); | |
const diffImage = comparator(baseImage, currImage); |
} | ||
} | ||
if (errors.length > 0) { | ||
throw `Differences found: ${errors.join(', ')}`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-throw-literal> reported by reviewdog 🐶
Expected an error object to be thrown.
throw `Differences found: ${errors.join(', ')}`; | ||
} | ||
}); | ||
|
||
Then(/^I should be able to use the "([^\"]*)" submenu$/, async function (menu) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-useless-escape> reported by reviewdog 🐶
Unnecessary escape character: ".
throw `Differences found: ${errors.join(', ')}`; | ||
} | ||
}); | ||
|
||
Then(/^I should be able to use the "([^\"]*)" submenu$/, async function (menu) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unexpected unnamed async function.
@@ -296,14 +341,3 @@ | |||
this.page.native = newPage; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <no-trailing-spaces> reported by reviewdog 🐶
Trailing spaces not allowed.
this.page.native = newPage; | |
this.page.native = newPage; |
DC MILO Release 0.2339