Ver Fonte

fix unit tests

Olivier Massot há 1 ano atrás
pai
commit
624304ebdb
1 ficheiros alterados com 4 adições e 2 exclusões
  1. 4 2
      tests/units/services/rights/abilityBuilder.test.ts

+ 4 - 2
tests/units/services/rights/abilityBuilder.test.ts

@@ -37,12 +37,14 @@ const doc = {
     },
   },
 }
-vi.mock('yaml-import', async () => {
+
+vi.mock('yaml-import', () => {
   return {
-    default: { read: vi.fn((data: string) => doc) },
+    read: vi.fn((data: string) => doc)
   }
 })
 
+
 beforeEach(() => {
   ability = vi.fn() as any as MongoAbility
   accessProfile = vi.fn() as any as AccessProfile