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

[Bug][Playwright] updates automated test cases to isManual=true #738

Open
robertgagnon726 opened this issue Feb 2, 2025 · 2 comments
Open

Comments

@robertgagnon726
Copy link

robertgagnon726 commented Feb 2, 2025

I'm running Playwright locally and using playwright-qase-reporter to link to Qase. However, when I set the following configuration in Qase, every published test case is being updated to isManual=true. It'd be chill if this didn't happen or if there was a config to toggle.

Versions:

    "playwright-qase-reporter": "^2.0.16",
    "playwright": "^1.48.0",

Related Playwright config

  reporter: [
    ['html'],
    [
      'playwright-qase-reporter',
      {
        testops: {
          api: {
            token: process.env.QASE_API_TOKEN,
          },
          project: 'XX',
          uploadAttachments: true,
          run: {
            complete: true,
          },
        },
      },
    ],
  ],

Test Case

import { ProspectSteps } from '@Playwright/common/steps/prospects.steps';
import { qase } from 'playwright-qase-reporter';
import { expect, test } from 'playwright/test';

test(qase(14, 'Cannot edit the property billing contact'), async ({ page }) => {
  qase.fields({ priority: 'high', });
  const prospectSteps = new ProspectSteps(page);

  await prospectSteps.openProspectsPage();
  await prospectSteps.openEditProspectModal();

  expect(await page.getByLabel('Existing contact*').isDisabled()).toBeTruthy();
});

Attached are the project configurations.

Image Image

I'm unable to set Update test cases from automated results without this happening which is rather frustrating. I'm just going to disable updates for now which is fine, but I wanted to bring some awareness.

@robertgagnon726
Copy link
Author

I've also confirmed that this does not resolve this issue as well:

test(qase(14, 'Cannot edit the property billing contact'), async ({ page }) => {
  //   qase.fields({ priority: 'high', isManual: 'false' });
  const prospectSteps = new ProspectSteps(page);

  await prospectSteps.openProspectsPage();
  await prospectSteps.openEditProspectModal();

  expect(await page.getByLabel('Existing contact*').isDisabled()).toBeTruthy();
});

@robertgagnon726 robertgagnon726 changed the title playwright-qase-reporter updates automated test cases to isManual=true [Bug][Playwright] updates automated test cases to isManual=true Feb 2, 2025
@gibiw
Copy link
Contributor

gibiw commented Feb 5, 2025

@robertgagnon726 Hi! Thanks for reaching out. Yes, this is indeed unexpected behavior, and we will try to fix it as soon as possible.

You can use a workaround. Add the field automation with the value automated when calling qase.fields:

test(qase(14, 'Cannot edit the property billing contact'), async ({ page }) => {
  qase.fields({ priority: 'high', automation: 'automated' });
  const prospectSteps = new ProspectSteps(page);

  await prospectSteps.openProspectsPage();
  await prospectSteps.openEditProspectModal();

  expect(await page.getByLabel('Existing contact*').isDisabled()).toBeTruthy();
});

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

No branches or pull requests

2 participants