Skip to content

Commit

Permalink
fix jest actions
Browse files Browse the repository at this point in the history
  • Loading branch information
ReDBrother committed Feb 12, 2024
1 parent fb6ee1d commit bec4c8f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 18 deletions.
36 changes: 18 additions & 18 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,29 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}

- name: Get yarn cache
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v3
id: yarn-cache
- name: Setup node
uses: actions/setup-node@v4
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
node-version: 20.x

- name: Yarn cache
uses: c-hive/gha-yarn-cache@v2

# - name: Get yarn cache
# id: yarn-cache-dir-path
# run: echo "::set-output name=dir::$(yarn cache dir)"
#
# - uses: actions/cache@v4
# id: yarn-cache
# with:
# path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
# key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
# restore-keys: |
# ${{ runner.os }}-yarn-

- name: Install yarn dependencies
run: yarn install --froze-lockfile
Expand All @@ -54,17 +61,10 @@ jobs:
- name: Run jest
run: yarn test

# - name: Setup db

- name: Login to Docker Hub
run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u ${{ secrets.DOCKER_USERNAME }} --pasword-stdin

- name: Build docker image for codebattle bot
run: make docker-build-chat-bot
- name: Push docker image for codebattle bot
run: make docker-push-chat-bot

# - name:
# run:
# uses:
# with:
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
"prepare": "husky",
"test": "jest"
},
"jest": {
"verbose": true
},
"repository": "[email protected]:hexlet-codebattle/codebattle_bot",
"author": "ReDBrother <[email protected]>",
"license": "MIT",
Expand Down

0 comments on commit bec4c8f

Please sign in to comment.