Closed nkaretnikov closed 9 months ago
Could you please explain the process you used to update the yarn lockfile in detailed steps?
As it stands, I don't know how to recreate this PR.
@gabalafou Happy to help, LMK if the following doesn't answer your questions.
I need to know how to generate the lockfile changes.
I did yarn install
locally, it updated the lockfile, I committed the lockfile to the repo, see:
https://stackoverflow.com/a/77300807
I need to know how to run the tests locally.
docker ps
to make sure no containers are running.yarn run start
. This will create containers needed for running the server and will start the UI as well.webpack 5.89.0 compiled successfully in 58181 ms
playwright_env.sh:
# export REACT_APP_AUTH_TOKEN=
export CONDA_STORE_SERVER_PORT='8000'
export CONDA_STORE_BASE_URL='http://localhost:8000'
export CONDA_STORE_AUTH='basic'
export CONDA_STORE_USERNAME='username'
export CONDA_STORE_PASSWORD='password'
export REACT_APP_API_URL='http://localhost:8080/conda-store/'
export REACT_APP_AUTH_METHOD='cookie'
export REACT_APP_LOGIN_PAGE_URL='http://localhost:8080/conda-store/login?next='
export REACT_APP_STYLE_TYPE='green-accent'
export REACT_APP_CONTEXT='webapp'
export REACT_APP_SHOW_AUTH_BUTTON='true'
export REACT_APP_LOGOUT_PAGE_URL='http://localhost:8080/conda-store/logout?next=/'
export YARN_ENABLE_IMMUTABLE_INSTALLS='false'
python test/playwright/test_ux.py
# pytest -rfxs test/playwright/test_ux.py -vvv --capture=no
╔════════════════════════════════════════════════════════════════════════════════════════════════╗
║ Looks like you launched a headed browser without having a XServer running. ║
║ Set either 'headless: true' or use 'xvfb-run <your-playwright-app>' before running Playwright. ║
║ ║
║ <3 Playwright Team ║
╚════════════════════════════════════════════════════════════════════════════════════════════════╝
diff --git a/test/playwright/test_ux.py b/test/playwright/test_ux.py
index dcf0782..ab7c42f 100644
--- a/test/playwright/test_ux.py
+++ b/test/playwright/test_ux.py
@@ -306,7 +306,7 @@ if __name__ == "__main__":
# Use playwright.chromium, playwright.firefox or playwright.webkit
# Pass headless=False to launch() to see the browser UI
# slow_mo adds milliseconds to each playwright command so humans can follow along
- browser = playwright.chromium.launch(headless=False, slow_mo=500)
+ browser = playwright.chromium.launch(headless=True, slow_mo=500)
page = browser.new_page()
# Go to http://localhost:{server_port}
pytest
I'd also add that these tests are passing on CI. So if there are any problems, make sure you have no other instances of conda-store running, etc.
Fixes playwright test failures introduced by a yarn update.
Description
This pull request:
Updates the lockfile to fix an issue caused by updated dependencies, which manifests on CI as follows:
Updates tests checking
Select
elements, which are generated with rolecombobox
after the lockfile update. For example, this shows the change to the code of theActive
button:Increases the timeout for building an env because the old value was flaky.
Pull request checklist
Additional information