Skip to content

Commit 96ea48b

Browse files
committed
test: migrate to vitest
1 parent 49f2253 commit 96ea48b

28 files changed

+17442
-23064
lines changed

.circleci/config.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,22 @@ orbs:
66
jobs:
77
unit:
88
docker:
9-
- image: cimg/node:18.18.0
9+
- image: cimg/node:20.19.4
1010
steps:
1111
- checkout
1212
- restore_cache:
13-
key: dependency-cache-{{ checksum "package.json" }}
14-
- run: npm install
13+
key: dependency-cache-{{ checksum "package-lock.json" }}
14+
- run: npm ci --prefer-offline
1515
- run: npm run build
1616
- run: npm run test:unit
1717
integration:
1818
docker:
19-
- image: cimg/node:18.18.0
19+
- image: cimg/node:20.19.4
2020
steps:
2121
- checkout
2222
- restore_cache:
23-
key: dependency-cache-{{ checksum "package.json" }}
24-
- run: npm install
23+
key: dependency-cache-{{ checksum "package-lock.json" }}
24+
- run: npm ci --prefer-offline
2525
- run: npm run build
2626
- run: npm run test:integration
2727
release:
@@ -31,7 +31,7 @@ jobs:
3131
- checkout
3232
- vault/get-secrets: # Loads vault secrets
3333
template-preset: "semantic-release-ecosystem"
34-
- run: npm install
34+
- run: npm ci --prefer-offline
3535
- run: npm run build
3636
- run: npm run semantic-release
3737
workflows:

.eslintrc.js renamed to .eslintrc.cjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ module.exports = {
22
parser: '@typescript-eslint/parser',
33
extends: [
44
'standard',
5-
'plugin:jest/recommended',
65
'plugin:@typescript-eslint/recommended' // Recommended TypeScript rules
76
],
87
plugins: ['standard', 'promise', '@typescript-eslint'],

jest.config.js

Lines changed: 0 additions & 11 deletions
This file was deleted.

lib/tasks/get-destination-data.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import Promise from 'bluebird'
22

3-
import { logEmitter } from 'contentful-batch-libs/dist/logging'
3+
import { logEmitter } from 'contentful-batch-libs'
44
import type { AssetProps, ContentTypeProps, EntryProps, LocaleProps, TagProps, WebhookProps } from 'contentful-management'
55
import { OriginalSourceData } from '../types'
66
import PQueue from 'p-queue'

lib/tasks/init-client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { createClient } from 'contentful-management'
22

3-
import { logEmitter } from 'contentful-batch-libs/dist/logging'
3+
import { logEmitter } from 'contentful-batch-libs'
44

55
function logHandler (level, data) {
66
logEmitter.emit(level, data)

lib/tasks/push-to-space/push-to-space.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import Listr from 'listr'
22
import verboseRenderer from 'listr-verbose-renderer'
33

4-
import { logEmitter } from 'contentful-batch-libs/dist/logging'
5-
import { wrapTask } from 'contentful-batch-libs/dist/listr'
4+
import { logEmitter, wrapTask } from 'contentful-batch-libs'
65

76
import * as assets from './assets'
87
import * as creation from './creation'

0 commit comments

Comments
 (0)