diff --git a/.circleci/config.yml b/.circleci/config.yml index 4b9e2fd..a9d18c7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,5 +1,11 @@ version: 2.1 # Define the jobs we want to run for this project +workflow: + build: + jobs: + - build + - lint + - tu jobs: build: docker: @@ -13,3 +19,20 @@ jobs: key: npm-v1-dependencies-{{ checksum "yarn.lock" }} paths: - ./node_modules + lint: + docker: + - image: cimg/node:14.10.1 + steps: + - checkout + - restore_cache: + key: npm-v1-dependencies-{{ checksum "yarn.lock" }} + - run: yarn lint & yarn format:check + + tu: + docker: + - image: cimg/node:14.10.1 + steps: + - checkout + - restore_cache: + key: npm-v1-dependencies-{{ checksum "yarn.lock" }} + - run: yarn test:ci diff --git a/package.json b/package.json index a4f54c1..96ef36c 100644 --- a/package.json +++ b/package.json @@ -20,8 +20,8 @@ "test:cov": "jest --coverage", "test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand", "test:e2e": "jest --config ./test/jest-e2e.json", - "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\" \"./**/*.{yaml,yml}\"", - "format:check": "prettier --list-different \"src/**/*.ts\" \"test/**/*.ts\" \"./**/*.{yaml,yml}\"", + "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"", + "format:check": "prettier --list-different \"src/**/*.ts\" \"test/**/*.ts\"", "generate": "hygen" }, "dependencies": {