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

Dashboard tests #7656

Merged
merged 71 commits into from
Oct 11, 2023
Merged

Dashboard tests #7656

merged 71 commits into from
Oct 11, 2023

Conversation

somebody1234
Copy link
Contributor

Pull Request Description

The purpose of this PR is to introduce the testing framework - more tests can be added later in separate PRs.

Important Notes

To test, run npm run test in app/ide-desktop, or app/ide-desktop/lib/dashboard/. All tests should pass.

Individual test types can be run using npm run test-unit, npm run test-component and npm run test-e2e in app/ide-desktop/lib/dashboard/.
Individual end-to-end tests can be run using npx playwright test -c playwright-e2e.config.ts test-e2e/<file name>.spec.ts in app/ide-desktop/lib/dashboard/.

End-to-end tests require internet access to pass (for things like fonts).

This PR does check in screenshots to guard against visual regessions (and/or to make visual changes obvious)

Checklist

Please ensure that the following checklist has been satisfied before submitting the PR:

  • The documentation has been updated, if necessary.
  • Screenshots/screencasts have been attached, if there are any visual changes. For interactive or animated visual changes, a screencast is preferred.
  • All code follows the
    Scala,
    Java,
    and
    Rust
    style guides. In case you are using a language not listed above, follow the Rust style guide.
  • All code has been tested:
    • Unit tests have been written where possible.
    • If GUI codebase was changed, the GUI was tested when built using ./run ide build.

@somebody1234 somebody1234 added the CI: No changelog needed Do not require a changelog entry for this PR. label Aug 24, 2023
@PabloBuchu
Copy link
Contributor

Lots of failed tests with missing snapshot errror..

Screenshot 2023-08-25 at 10 00 25

@somebody1234
Copy link
Contributor Author

@PabloBuchu that seems to be because the snapshots are platform-specific. i think that's a good thing, because some things (like context menus) are different on each platform. i think the correct move here would be to git add -A + commit + push?

@somebody1234
Copy link
Contributor Author

speaking of though, that means these should be run on windows too

@somebody1234
Copy link
Contributor Author

lint check is failing though, one moment...

@somebody1234
Copy link
Contributor Author

somebody1234 commented Aug 25, 2023

I think this should have some CI changes, since we should test for visual regressions on all platforms, but I think maybe that should wait until it's confirmed that we want to merge this (or wait until this is actually merged in, so that there's something to run in those CI actions)

@somebody1234
Copy link
Contributor Author

for anyone testing: this does have new folders (caches, test results) which are .gitignored, remember to git add -A; git reset --hard when switching away from this branch

It does not work in Ubuntu runners without extra dependencies
@somebody1234
Copy link
Contributor Author

somebody1234 commented Oct 10, 2023

what, why did lint hang

@somebody1234 somebody1234 force-pushed the wip/sb/dashboard-tests branch from 76c1f90 to 8160a37 Compare October 10, 2023 09:09
@somebody1234
Copy link
Contributor Author

:D lint finally passes!!!

@somebody1234
Copy link
Contributor Author

this should still get updated screenshots from macos and windows though. (cc @PabloBuchu)

@somebody1234
Copy link
Contributor Author

:D (visual regression tests)

image

@PabloBuchu PabloBuchu added the CI: Ready to merge This PR is eligible for automatic merge label Oct 11, 2023
@mergify mergify bot merged commit 3c31155 into develop Oct 11, 2023
30 checks passed
@mergify mergify bot deleted the wip/sb/dashboard-tests branch October 11, 2023 10:24
mergify bot pushed a commit that referenced this pull request Oct 11, 2023
Removes dependencies that should not be in the root `package.json`
Basic testing done with `npm run ci-check`.

Introduced by the following PRs (in order of being merged):
See blame for more details: https://github.com/enso-org/enso/blame/develop/package.json
- #7813
- #7656 (oops)
- #7881

# Important Notes
None
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI: Clean build required CI runners will be cleaned before and after this PR is built. CI: No changelog needed Do not require a changelog entry for this PR. CI: Ready to merge This PR is eligible for automatic merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants