-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
39 additions
and
29 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,39 @@ | ||
#name: Ruby | ||
# | ||
#on: | ||
# push: | ||
# branches: | ||
# - master | ||
# | ||
# pull_request: | ||
# | ||
#jobs: | ||
# build: | ||
# runs-on: ubuntu-latest | ||
# name: Ruby ${{ matrix.ruby }} | ||
# strategy: | ||
# matrix: | ||
# ruby: | ||
# - '3.1.3' | ||
# | ||
# steps: | ||
# - uses: actions/checkout@v4 | ||
# - name: Set up Ruby & Rust | ||
# uses: oxidize-rb/actions/setup-ruby-and-rust@v1 | ||
# with: | ||
# ruby-version: ${{ matrix.ruby }} | ||
# bundler-cache: true | ||
# cargo-cache: true | ||
# rubygems: '3.4.22' | ||
# - name: Run the default task | ||
# run: bundle exec rake | ||
name: Main | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
name: Lint | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Up docker | ||
run: docker compose up -d ruby-rust | ||
- name: Check rubocop | ||
run: docker compose exec ruby-rust /bin/bash -c 'bundle exec rake rubocop' | ||
- name: Check syntax tree | ||
run: docker compose exec ruby-rust /bin/bash -c 'bundle exec rake stree:check' | ||
- name: Check Rust | ||
run: docker compose exec ruby-rust /bin/bash -c 'cargo clippy' | ||
test-ruby: | ||
runs-on: ubuntu-latest | ||
name: Ruby-${{ matrix.ruby }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
ruby: | ||
- '3.0.2' | ||
- '3.1.4' | ||
- '3.2.2' | ||
- '3.3.0' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Up docker | ||
run: RUBY_VERSION=${{ matrix.ruby }} docker compose up -d ruby-rust | ||
- name: Run Tests | ||
run: docker compose exec ruby-rust /bin/bash -c 'bundle exec rake compile && bundle exec rake spec' |