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

UI never connects when using run #2897

Open
6 tasks done
Weetbix opened this issue Feb 22, 2023 · 2 comments · May be fixed by #2915
Open
6 tasks done

UI never connects when using run #2897

Weetbix opened this issue Feb 22, 2023 · 2 comments · May be fixed by #2915
Labels
documentation Improvements or additions to documentation pr welcome

Comments

@Weetbix
Copy link

Weetbix commented Feb 22, 2023

Describe the bug

The never gets past the "connecting" stage when running with vitest run, but works fine with vitest watch.

Not sure if this is so much a bug, or just unsupported. But I cant see why it shouldnt work, and for larger test suites that can take minutes to run it makes sense to provide the UI.

Reproduction

https://stackblitz.com/edit/vitest-dev-vitest-shyza9?file=package.json

System Info

System:
    OS: macOS 13.2.1
    CPU: (8) arm64 Apple M1
    Memory: 138.16 MB / 16.00 GB
    Shell: 5.8.1 - /bin/zsh
  Binaries:
    Node: 16.13.2 - ~/.nvm/versions/node/v16.13.2/bin/node
    Yarn: 1.22.19 - ~/.nvm/versions/node/v16.13.2/bin/yarn
    npm: 8.1.2 - ~/.nvm/versions/node/v16.13.2/bin/npm
  Browsers:
    Firefox: 97.0.1
    Safari: 16.3
  npmPackages:
    @vitejs/plugin-vue: 4.0.0 => 4.0.0
    @vitest/ui: ^0.28.5 => 0.28.5
    vite: ^4.1.4 => 4.1.4
    vitest: ^0.28.5 => 0.28.5

Used Package Manager

yarn

Validations

@sheremet-va
Copy link
Member

It's not supported for "run" mode. You can use html reporter instead to get generated HTML page with the same results.

@Weetbix
Copy link
Author

Weetbix commented Feb 24, 2023

Hey :) Maybe this should be a feature request then?

Would be good if it was noted somewhere in the docs, as it doesn't currently mention that. I would also expect the --ui flag not to run the UI server and open the page in that case too. I found it pretty confusing and lost some time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation pr welcome
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants