diff --git a/package.json b/package.json index 48d25d200..cf7a99b0a 100644 --- a/package.json +++ b/package.json @@ -162,7 +162,7 @@ "test:instantPowerResolver": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/resolvers/instantPowerResolver.test.ts", "test:fillSnapshotBalance": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/services/cronJobs/fillSnapshotBalances.test.ts", "test:projectAddressRepository": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/repositories/projectAddressRepository.test.ts", - "test:donationService": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/services/donationService.test.ts", + "test:donationService": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/repositories/qfRoundHistoryRepository.test.ts ./src/services/donationService.test.ts", "test:userService": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/services/userService.test.ts", "test:reactionsService": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/services/reactionsService.test.ts", "test:powerSnapshotService": "NODE_ENV=test mocha ./test/pre-test-scripts.ts ./src/services/powerSnapshotServices.test.ts", diff --git a/src/services/donationService.test.ts b/src/services/donationService.test.ts index 2dc65f72d..c92cae787 100644 --- a/src/services/donationService.test.ts +++ b/src/services/donationService.test.ts @@ -885,6 +885,9 @@ function insertDonationsFromQfRoundHistoryTestCases() { }); it('should return correct value for single project', async () => { + // First call it to make sure there isnt any thing in DB to make conflicts in our test cases + await insertDonationsFromQfRoundHistory(); + const usersDonations: number[][] = [ [1, 3], // 4 [2, 23], // 25