Use canonical Rails checkout path in CI

This commit is contained in:
2026-07-18 23:10:40 -07:00
parent 105550a8b4
commit f2e5e4a362
2 changed files with 7 additions and 6 deletions

View File

@@ -148,29 +148,29 @@ jobs:
with: with:
repository: ajaynomics/opencode-rails repository: ajaynomics/opencode-rails
ref: ${{ needs.prepare.outputs.rails_ref }} ref: ${{ needs.prepare.outputs.rails_ref }}
path: rails-client path: opencode-rails
fetch-depth: 0 fetch-depth: 0
fetch-tags: true fetch-tags: true
- uses: ruby/setup-ruby@003a5c4d8d6321bd302e38f6f0ec593f77f06600 # v1 - uses: ruby/setup-ruby@003a5c4d8d6321bd302e38f6f0ec593f77f06600 # v1
with: with:
ruby-version: ${{ matrix.ruby }} ruby-version: ${{ matrix.ruby }}
bundler-cache: true bundler-cache: true
working-directory: rails-client working-directory: opencode-rails
- name: Verify immutable candidate checkouts - name: Verify immutable candidate checkouts
env: env:
EXPECTED_RUBY_SHA: ${{ needs.prepare.outputs.ruby_ref }} EXPECTED_RUBY_SHA: ${{ needs.prepare.outputs.ruby_ref }}
EXPECTED_RAILS_SHA: ${{ needs.prepare.outputs.rails_ref }} EXPECTED_RAILS_SHA: ${{ needs.prepare.outputs.rails_ref }}
run: | run: |
test "$(git -C ruby-client rev-parse HEAD)" = "$EXPECTED_RUBY_SHA" test "$(git -C ruby-client rev-parse HEAD)" = "$EXPECTED_RUBY_SHA"
test "$(git -C rails-client rev-parse HEAD)" = "$EXPECTED_RAILS_SHA" test "$(git -C opencode-rails rev-parse HEAD)" = "$EXPECTED_RAILS_SHA"
- name: Rails candidate unit tests - name: Rails candidate unit tests
working-directory: rails-client working-directory: opencode-rails
run: bundle exec rake test run: bundle exec rake test
- name: Lockstep client provenance contract - name: Lockstep client provenance contract
working-directory: rails-client working-directory: opencode-rails
env: env:
OPENCODE_RUBY_PATH: ${{ github.workspace }}/ruby-client OPENCODE_RUBY_PATH: ${{ github.workspace }}/ruby-client
OPENCODE_RAILS_PATH: ${{ github.workspace }}/rails-client OPENCODE_RAILS_PATH: ${{ github.workspace }}/opencode-rails
OPENCODE_RUBY_COMMIT: ${{ needs.prepare.outputs.ruby_ref }} OPENCODE_RUBY_COMMIT: ${{ needs.prepare.outputs.ruby_ref }}
OPENCODE_RUBY_TAG: ${{ needs.prepare.outputs.ruby_tag }} OPENCODE_RUBY_TAG: ${{ needs.prepare.outputs.ruby_tag }}
OPENCODE_RUBY_TAG_OBJECT: ${{ needs.prepare.outputs.ruby_tag_object }} OPENCODE_RUBY_TAG_OBJECT: ${{ needs.prepare.outputs.ruby_tag_object }}

View File

@@ -183,6 +183,7 @@ class RepositoryTest < Minitest::Test
refute_includes workflow, "inputs.opencode_rails_ref" refute_includes workflow, "inputs.opencode_rails_ref"
assert_includes workflow, "repository: ajaynomics/opencode-ruby" assert_includes workflow, "repository: ajaynomics/opencode-ruby"
assert_includes workflow, "repository: ajaynomics/opencode-rails" assert_includes workflow, "repository: ajaynomics/opencode-rails"
assert_includes workflow, "path: opencode-rails"
assert_includes workflow, "ruby: [\"3.2\", \"3.3\", \"3.4\"]" assert_includes workflow, "ruby: [\"3.2\", \"3.3\", \"3.4\"]"
assert_includes workflow, "ruby/lockstep_client_contract.rb" assert_includes workflow, "ruby/lockstep_client_contract.rb"
assert_includes workflow, "OPENCODE_RUBY_TAG_OBJECT" assert_includes workflow, "OPENCODE_RUBY_TAG_OBJECT"