1
0

vitest.config.ts 772 B

12345678910111213141516171819202122232425262728293031
  1. /**
  2. * SPDX-FileCopyrightText: 2023-2024 Nextcloud GmbH and Nextcloud contributors
  3. * SPDX-License-Identifier: CC0-1.0
  4. */
  5. import { defineConfig } from 'vitest/config'
  6. import vue from '@vitejs/plugin-vue2'
  7. export default defineConfig({
  8. plugins: [vue()],
  9. test: {
  10. include: ['{apps,core}/**/*.{test,spec}.?(c|m)[jt]s?(x)'],
  11. environment: 'jsdom',
  12. environmentOptions: {
  13. jsdom: {
  14. url: 'http://nextcloud.local',
  15. },
  16. },
  17. coverage: {
  18. include: ['apps/*/src/**', 'core/src/**'],
  19. exclude: ['**.spec.*', '**.test.*', '**.cy.*', 'core/src/tests/**'],
  20. provider: 'v8',
  21. reporter: ['lcov', 'text'],
  22. },
  23. setupFiles: ['__tests__/mock-window.js', '__tests__/setup-testing-library.js'],
  24. server: {
  25. deps: {
  26. inline: [/@nextcloud\//],
  27. },
  28. },
  29. },
  30. })