Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
19 views

I am getting an error "ApolloError: No more mocked responses for the query: mutation CreatePost($text: String!, $title: String!, $imageUrl: URL, $videoUrl: URL, $organizationId: ID!, $file: ...
Amaan_aly's user avatar
4 votes
1 answer
826 views

I have a monorepo with an Angular project and a few Node.js projects. Running vitest locally, all tests are passing. However, in GitHub Actions, the Angular tests are failing. GitHub Actions test ...
Christopher Peisert's user avatar
-1 votes
1 answer
94 views

Jest and Vitest by default run test files in parallel. An issue with this is that the console.log from different test files are interleaved. Is there a way to run the tests in parallel, but save the ...
stackoverflower's user avatar
3 votes
1 answer
1k views

Is there a built-in way in Drizzle ORM to generate the CREATE TABLE IF NOT EXISTS SQL directly from the pgTable schema definition? Here’s an example of how I’m currently setting up an in-memory pglite ...
codeBelt's user avatar
  • 1,815
1 vote
1 answer
700 views

I just created an app with pnpx sv create sveltekit-test2 and checked vitest and now when I run pnpm check I get this error: Loading svelte-check in workspace: /home/sas/devel/apps/dgiit/proyectos/tmp/...
opensas's user avatar
  • 64.4k
0 votes
1 answer
76 views

I have created a custom hook as follows: import { getUserInfo } from '@/scripts/services/userService'; import { useState, useEffect } from 'react'; const useFileFilter = (repositoryFiles: any[]) =>...
Snackoverflow's user avatar
0 votes
0 answers
247 views

I want to write tests for the following function using Vitest. import { randomUUID } from "node:crypto"; export const getRandomUUID = (): string => { return randomUUID(); } I wrote ...
qqq_ts_react's user avatar
0 votes
3 answers
1k views

Github Repo: https://github.com/Gaban-Ventures/crypto-basis-frontend With the latest commit you have to run npm install --legacy-peer-deps To run normal before the breaking tests, do: git co ...
Leon Gaban's user avatar
  • 39.4k
0 votes
1 answer
3k views

I’m having trouble using the toBeInTheDocument matcher with Vitest and @testing-library/jest-dom in my TypeScript project. Even though I have installed and configured everything correctly, I’m still ...
Akshat Parashar's user avatar
0 votes
0 answers
69 views

I am building a Svelte component library for my project and have run into several issues, particularly when trying to test components with slots. Here's the error I'm facing: Object literal may only ...
Józef Podlecki's user avatar
-2 votes
1 answer
139 views

I have a simple test case: import {describe, it, test} from "vitest"; import {decodeBase64, hexlify} from "ethers"; describe('zapModule', () => { it('smoke test vitest', ...
Konstantin Pribluda's user avatar
0 votes
0 answers
138 views

I'm looking for a way to mock multiple refs (and refs in general) in Nuxt? I'm using Vitest and Nuxt test utils. About my Case: I want to test a SideBar.vue component. The component has multiple refs: ...
Leo Gall's user avatar
0 votes
1 answer
647 views

I'm trying to write a unit test for an onMounted lifecycle hook for my Vue 3 component. I'm mocking the resolved value for an async call but it keeps returning undefined. As a result my last expect ...
Joe King's user avatar
0 votes
1 answer
526 views

Background: Vue3 app, using Vuetify, vitest, and vue-testing-library. Problem: I have a custom component whose template looks something like this: <template> <v-expansion-panel> ... ...
Andres Rosales's user avatar
2 votes
0 answers
35 views

Im currently writing tests for a Vue component (Calendar.vue) for that I need to get the array generated by the fillArray() function. My aproach is to read out the props of the Day.vue component but ...
Leander's user avatar
  • 21
1 vote
1 answer
60 views

This problem happens in testing environments. when I try to import an enum from @prisma/client it returns undefined... import { DailyTip } from "@prisma/client"; describe("test", (...
Reza Attar's user avatar
0 votes
0 answers
61 views

After the third line, the code in the pages folder was not covered when selecting the v8 for coverage. How can I achieve this? I have provided the configuration and code changes in below. Vitest....
syed wajith's user avatar
1 vote
1 answer
2k views

I using vitest for my testing environment, and after creating a new test, I'm getting the following error in my console: Error: No test found in suite I'm not sure what I'm doing wrong. Here's my ...
Jasperan's user avatar
  • 4,945
-1 votes
2 answers
103 views

I need help regarding a specific test. I have a Component, that is toggling the sound on and off in my project. The last test, with which I try to test if the e.prevenDefault gets called does not work,...
Mawin's user avatar
  • 19
0 votes
1 answer
33 views

When I run the test getting the error as: Error: Failed to resolve import "@/components/card/LoadingCards" from "app/page.tsx". Does the file exist? Plugin: vite:import-analysis ...
3gwebtrain's user avatar
  • 15.5k
0 votes
1 answer
116 views

I wanna test my route. The problem is that I can't mock "multer" multiple times with different content. My Test: import request from "supertest"; import express from "express&...
Flo's user avatar
  • 3,302
2 votes
1 answer
394 views

We have a Vitest setup for Vite-based React project using MUI. When we create a snapshot of a component, the class part will have hashed classnames like the following: <div class="...
Erik Kránicz's user avatar
1 vote
0 answers
34 views

I am writing mocks responses (using MSW) for a test case for an API call when a page is rendered in vitest and I am unable to trigger the REST API call defined in a handler. Technically, if the API is ...
johnathan chan's user avatar
4 votes
0 answers
1k views

I using Vitest with React to make tests. I want to make a "simple" test, to simulate a basic user for my app. The test, when I run npm run test works, the problem is that if I make a change ...
Juan Andrés Romero's user avatar
0 votes
1 answer
250 views

I would like to add some tests that actually try to load Popup.vue and ToolTip.vue in my project. The source code is in git at: https://github.com/geewhizbang/gw-popup It's not that the popup doesn't ...
GeeWhizBang's user avatar

1 2
3
4 5
19