Tobi T4 consensus: alpha gems shouldn't ship without proof that 'bundle exec rake test' passes on push. Workflow runs the test suite + gem build + post-install smoke load on Ruby 3.2, 3.3, and 3.4. Workflow will activate when the repo moves to GitHub. Local 'bundle exec rake test' continues to be the dev feedback loop.
35 lines
722 B
YAML
35 lines
722 B
YAML
name: Test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
ruby: ["3.2", "3.3", "3.4"]
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Set up Ruby ${{ matrix.ruby }}
|
|
uses: ruby/setup-ruby@v1
|
|
with:
|
|
ruby-version: ${{ matrix.ruby }}
|
|
bundler-cache: true
|
|
|
|
- name: Run tests
|
|
run: bundle exec rake test
|
|
|
|
- name: Build gem
|
|
run: gem build opencode-ruby.gemspec
|
|
|
|
- name: Verify gem loads after install
|
|
run: |
|
|
gem install --local opencode-ruby-*.gem
|
|
ruby -ropencode-ruby -e 'puts Opencode::VERSION'
|