Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/acceptance-tests-on-emulator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ jobs:
max-parallel: 4
matrix:
ruby: ["3.2", "3.3", "3.4", "4.0"]
ar: ["~> 7.0.0", "~> 7.1.0", "~> 7.2.0", "~> 8.0.0", "~> 8.1.0"]
ar: ["7.0", "7.1", "7.2", "8.0", "8.1"]
# Exclude combinations that are not supported.
exclude:
- ruby: "3.4"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "3.4"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "3.4"
ar: "~> 7.2.0"
ar: "7.2"
- ruby: "4.0"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "4.0"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "4.0"
ar: "~> 7.2.0"
ar: "7.2"
env:
AR_VERSION: ${{ matrix.ar }}
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ar }}.gemfile
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,23 +15,23 @@ jobs:
max-parallel: 4
matrix:
ruby: ["3.2", "3.3", "3.4", "4.0"]
ar: ["~> 7.0.0", "~> 7.1.0", "~> 7.2.0", "~> 8.0.0", "~> 8.1.0"]
ar: ["7.0", "7.1", "7.2", "8.0", "8.1"]
# Exclude combinations that are not supported.
exclude:
- ruby: "3.4"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "3.4"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "3.4"
ar: "~> 7.2.0"
ar: "7.2"
- ruby: "4.0"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "4.0"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "4.0"
ar: "~> 7.2.0"
ar: "7.2"
env:
AR_VERSION: ${{ matrix.ar }}
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ar }}.gemfile
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/nightly-acceptance-tests-on-emulator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ jobs:
max-parallel: 4
matrix:
ruby: ["3.2", "3.3", "3.4", "4.0"]
ar: ["~> 7.0.0", "~> 7.1.0", "~> 7.2.0", "~> 8.0.0", "~> 8.1.0"]
ar: ["7.0", "7.1", "7.2", "8.0", "8.1"]
# Exclude combinations that are not supported.
exclude:
- ruby: "3.4"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "3.4"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "3.4"
ar: "~> 7.2.0"
ar: "7.2"
- ruby: "4.0"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "4.0"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "4.0"
ar: "~> 7.2.0"
ar: "7.2"
env:
AR_VERSION: ${{ matrix.ar }}
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ar }}.gemfile
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/nightly-unit-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,23 @@ jobs:
matrix:
# Run acceptance tests all supported combinations of Ruby and ActiveRecord.
ruby: ["3.2", "3.3", "3.4", "4.0"]
ar: ["~> 7.0.0", "~> 7.1.0", "~> 7.2.0", "~> 8.0.0", "~> 8.1.0"]
ar: ["7.0", "7.1", "7.2", "8.0", "8.1"]
# Exclude combinations that are not supported.
exclude:
- ruby: "3.4"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "3.4"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "3.4"
ar: "~> 7.2.0"
ar: "7.2"
- ruby: "4.0"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "4.0"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "4.0"
ar: "~> 7.2.0"
ar: "7.2"
env:
AR_VERSION: ${{ matrix.ar }}
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ar }}.gemfile
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/samples.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,23 @@ jobs:
max-parallel: 4
matrix:
ruby: ["3.2", "3.3", "3.4", "4.0"]
ar: ["~> 7.0.0", "~> 7.1.0", "~> 7.2.0", "~> 8.0.0"]
ar: ["7.0", "7.1", "7.2", "8.0"]
# Exclude combinations that are not supported.
exclude:
- ruby: "3.4"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "3.4"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "3.4"
ar: "~> 7.2.0"
ar: "7.2"
- ruby: "4.0"
ar: "~> 7.0.0"
ar: "7.0"
- ruby: "4.0"
ar: "~> 7.1.0"
ar: "7.1"
- ruby: "4.0"
ar: "~> 7.2.0"
ar: "7.2"
env:
AR_VERSION: ${{ matrix.ar }}
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.ar }}.gemfile
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ build-iPhoneSimulator/

# for a library or gem, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
Gemfile.lock
.ruby-version
.ruby-gemset

Expand Down
2 changes: 2 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ inherit_gem:
AllCops:
Exclude:
- "activerecord-spanner-adapter.gemspec"
- "Appraisals"
- "Gemfile"
- "gemfiles/*"
- "Rakefile"
- "bin/*"
- "test/**/*"
Expand Down
20 changes: 20 additions & 0 deletions Appraisals
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
appraise "7.0" do
gem "activerecord", "~> 7.0.0"
gem "composite_primary_keys" unless ENV["SKIP_COMPOSITE_PK"]
end

appraise "7.1" do
gem "activerecord", "~> 7.1.0"
end

appraise "7.2" do
gem "activerecord", "~> 7.2.0"
end

appraise "8.0" do
gem "activerecord", "~> 8.0.0"
end

appraise "8.1" do
gem "activerecord", "~> 8.1.0"
end
31 changes: 14 additions & 17 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,26 @@ source "https://rubygems.org"
# Specify your gem's dependencies in activerecord-spanner.gemspec
gemspec

ar_version = ENV.fetch("AR_VERSION", "~> 7.1.0")
gem "activerecord", ar_version
gem "ostruct"
unless ENV["APPRAISAL_INITIALIZED"] || ENV["APPRAISAL_UNDER_TEST"] || (ENV["BUNDLE_GEMFILE"] && ENV["BUNDLE_GEMFILE"].include?("gemfiles/"))
ar_version = ENV.fetch("AR_VERSION", "~> 7.1.0")
gem "activerecord", ar_version
end
gem "docker-api"
gem "irb"
gem "minitest", "~> 5.27.0"
gem "minitest-rg", "~> 5.4.0"
gem "mutex_m"
gem "ostruct"
gem "pry", "~> 0.16.0"
gem "pry-byebug", "~> 3.12.0"
gem "readline"
gem "mutex_m"
gem "irb"
gem "sinatra-activerecord"
# Add sqlite3 for testing for compatibility with other adapters.
gem 'sqlite3'
gem "sqlite3"

# Required for samples and testing.
install_if -> { ar_version.dup.to_s.sub("~>", "").strip < "7.1.0" && !ENV["SKIP_COMPOSITE_PK"] } do
gem "composite_primary_keys"
end

# Required for samples
gem "docker-api"
gem "sinatra-activerecord"

# Force google-protobuf to compile from source to avoid ABI issues in CI
if ENV["CI"]
gem "google-protobuf", force_ruby_platform: true
unless ENV["APPRAISAL_INITIALIZED"] || ENV["APPRAISAL_UNDER_TEST"] || (ENV["BUNDLE_GEMFILE"] && ENV["BUNDLE_GEMFILE"].include?("gemfiles/"))
if ar_version.dup.to_s.sub("~>", "").strip < "7.1.0" && !ENV["SKIP_COMPOSITE_PK"]
gem "composite_primary_keys"
end
end
Loading
Loading