Skip to content
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

chore: use github ci #640

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

chore: use github ci #640

wants to merge 1 commit into from

Conversation

KuznetsovRoman
Copy link
Member

No description provided.

@KuznetsovRoman KuznetsovRoman force-pushed the TRIVIAL.use_gh_ci branch 27 times, most recently from b7d25f8 to 7400473 Compare March 19, 2025 00:06
Copy link

github-actions bot commented Mar 19, 2025

✅ Testplane run succeed

@KuznetsovRoman KuznetsovRoman force-pushed the TRIVIAL.use_gh_ci branch 26 times, most recently from 7efeb5c to aec1134 Compare March 19, 2025 23:45
destination_dir: ${{ env.DEST_REPORTS_DIR }}
keep_files: true

- name: Construct failed PR comment
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't figure out smarter way to do this.
I tried constructing variables like STEP_TESTPLANE_TESTPLANE_COMMON_OUTCOME and evaluating them, but it does not work

@@ -38,7 +38,7 @@ test.describe('failed describe', () => {
test('test with successful assertView and error', async ({page, baseURL}) => {
await page.goto(baseURL as string);

await expect(page.locator('header')).toHaveScreenshot('header-success.png');
await expect(page.locator('header')).toHaveScreenshot('header-success.png', {maxDiffPixelRatio: 1});
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As its "test with successful assertView" (fixture), we can make this test 100% stable

@@ -8,6 +8,6 @@ describe('success describe', function() {
it('test with screenshot', async ({browser}) => {
await browser.url(browser.options.baseUrl);

await browser.assertView('header', 'header');
await browser.assertView('header', 'header', {ignoreDiffPixelCount: '100%'});
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As its "success-describe" (fixture), we can make this test 100% stable

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copied from "testplane-gui"

Comment on lines +29 to +34
}).on('error', err => {
if (err.code === 'EADDRINUSE') {
console.warn(`Skip running server, because port ${port} is busy`);
} else {
throw err;
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • We run Testplane (which uses this html-reporter-test-server and opens the server on SERVER_PORT)
    • Testplane runs Testplane GUI (port GUI_PORT)
      • Testplane GUI uses html-reporter-test-server and tries to run server on SERVER_PORT

getTestStateByNameSelector('header') +
getElementWithTextSelector('span', field) + '/..'
);
const errorMessage = await parentElement.$(getElementWithTextSelector('span', field) + '/..');
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason, it didn't work that way (though only for "name")

@@ -15,7 +15,7 @@ describe('Test redux plugin', function() {
await browser.$(screenSelector).waitForDisplayed();
await browser.$(clickSelector).click();
// Letting browser handle re-renders
await browser.pause(300);
await browser.pause(1000);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

500 wasn't enough either

Comment on lines +202 to +205
- name: Leave failed comment to PR with link to Testplane HTML reports
if: env.IS_FAILED
id: leave-failed-comment-step
uses: thollander/actions-comment-pull-request@v3
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Example:
Screenshot 2025-03-20 at 02 28 22

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant