Update dependency puma to v6.6.0 #1237
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: [push] | |
jobs: | |
backend-test: | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres:15.10-alpine | |
ports: | |
- 5432:5432 | |
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
env: | |
POSTGRES_HOST_AUTH_METHOD: trust | |
POSTGRES_USER: postgres | |
POSTGRES_PASSWORD: postgres | |
redis: | |
image: redis:alpine | |
options: --health-cmd "redis-cli -h localhost ping" --health-interval 10s --health-timeout 5s --health-retries 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Move to top directory | |
env: | |
SUB_DIR: backend | |
run: | | |
path=`pwd` | |
mv $path/$SUB_DIR /tmp | |
for dir in `find $path -maxdepth 0` | |
do | |
rm -rf $dir | |
done | |
for dir in `find /tmp/$SUB_DIR -maxdepth 0` | |
do | |
mv $dir $path | |
done | |
- name: Set Env | |
run: | | |
echo "RAILS_ENV=test" >> $GITHUB_ENV | |
echo "TEST_PG_USER=postgres" >> $GITHUB_ENV | |
echo "TEST_PG_PASSWORD=postgres" >> $GITHUB_ENV | |
echo "TEST_PG_HOST=localhost" >> $GITHUB_ENV | |
echo "REDIS_HOST=localhost:6379" >> $GITHUB_ENV | |
echo "REDIS_PASSWORD=" >> $GITHUB_ENV | |
echo "[email protected]" >> $GITHUB_ENV | |
echo "ADMIN_PASSWORD=password" >> $GITHUB_ENV | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 3.4.1 | |
bundler-cache: true | |
- name: DB setup | |
run: bundle exec rails db:setup | |
- name: Run rails test | |
run: bundle exec rspec | |
- name: Run rubocop | |
run: if (bundle exec rubocop -A) | grep -E "(corrected|\ W:\ )"; then exit 1; fi | |
frontend-test: | |
runs-on: ubuntu-latest | |
env: | |
NODE_VERSION: 20 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Move to top directory | |
env: | |
SUB_DIR: frontend | |
run: | | |
path=`pwd` | |
mv $path/$SUB_DIR /tmp | |
for dir in `find $path -maxdepth 0` | |
do | |
rm -rf $dir | |
done | |
for dir in `find /tmp/$SUB_DIR -maxdepth 0` | |
do | |
mv $dir $path | |
done | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ env.NODE_VERSION }} | |
- name: cache node_modules | |
id: node_modules_cache_id | |
uses: actions/cache@v4 | |
with: | |
path: | | |
node_modules | |
key: frontend-node-v${{ env.NODE_VERSION }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/yarn.lock')) }} | |
- name: Yarn install | |
run: yarn --cwd frontend install | |
- name: Prettier && ESLint | |
run: yarn --cwd frontend next lint |