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

refactor(elements/ino-fab): migrate stencil e2e tests to spec test #1278

Merged
merged 13 commits into from
Mar 15, 2024

Conversation

BenPag
Copy link
Collaborator

@BenPag BenPag commented Feb 26, 2024

Part of #1258

Proposed Changes

  • migrate tests to playwright
  • split test up into playwright and jest unit tests
  • disable shadow down for ino-fab and ino-fab-set

Comment on lines 12 to 20
test('should not open the dial by click', async () => {
const { width, height } = await inoFabSet.boundingBox();
await inoFabSet.click();
const { width: openWidth, height: openHeight } =
await inoFabSet.boundingBox();

expect(openWidth).toEqual(width);
expect(openHeight).toBeGreaterThan(height * 2);
});
Copy link
Collaborator

Choose a reason for hiding this comment

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

Instead of checking for the height, can't we just check for the visibility of the FABs?

Pseudocode:

expect(fabs).not.toBeVisible()
await inoFabSet.click()
expect(fabs).toBeVisible()

@janivo
Copy link
Collaborator

janivo commented Mar 14, 2024

Is there a specific reason, why you disabled the shadow dom?

@BenPag
Copy link
Collaborator Author

BenPag commented Mar 14, 2024

Is there a specific reason, why you disabled the shadow dom?

With shadow dom i was not able to test the components in jest.

@janivo janivo merged commit 0e27886 into master Mar 15, 2024
7 checks passed
@janivo janivo deleted the elements-ino-fab-migrate-tests branch March 15, 2024 17:00
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.

2 participants