Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: test adapter #436

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
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
9 changes: 5 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ jobs:
ports: ['5432:5432']
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: closure_tree
POSTGRES_DB: closure_tree_test
options: >-
--health-cmd pg_isready
Expand All @@ -50,9 +51,9 @@ jobs:
- activerecord_6.1
- activerecord_edge
adapter:
- 'sqlite3:///:memory:'
- mysql2://root:root@0/closure_tree_test
- postgres://closure_tree:closure_tree@0/closure_tree_test
- 'sqlite3:///tmp/closure_tree_test.sqlite3'
- mysql2://root:root@127.0.0.1:3306/closure_tree_test
- postgres://closure_tree:closure_tree@localhost:5432/closure_tree_test
exclude:
- ruby: '3.0'
rails: activerecord_edge
Expand All @@ -74,7 +75,7 @@ jobs:
- name: RSpec
env:
RAILS_VERSION: ${{ matrix.rails }}
DB_ADAPTER: ${{ matrix.adapter }}
DATABASE_URL: ${{ matrix.adapter }}
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
WITH_ADVISORY_LOCK_PREFIX: ${{ github.run_id }}
run: bin/rake
9 changes: 5 additions & 4 deletions .github/workflows/ci_jruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ jobs:
ports: ['5432:5432']
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: closure_tree
POSTGRES_DB: closure_tree_test
options: >-
--health-cmd pg_isready
Expand All @@ -43,9 +44,9 @@ jobs:
- activerecord_7.0
- activerecord_6.1
adapter:
- 'sqlite3:///:memory:'
- mysql2://root:root@0/closure_tree_test
- postgres://closure_tree:closure_tree@0/closure_tree_test
- 'sqlite3:///tmp/closure_tree_test.sqlite3'
- mysql2://root:root@127.0.0.1:3306/closure_tree_test
- postgres://closure_tree:closure_tree@localhost:5432/closure_tree_test
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -63,7 +64,7 @@ jobs:
- name: RSpec
env:
RAILS_VERSION: ${{ matrix.rails }}
DB_ADAPTER: ${{ matrix.adapter }}
DATABASE_URL: ${{ matrix.adapter }}
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
WITH_ADVISORY_LOCK_PREFIX: ${{ github.run_id }}
run: bin/rake
10 changes: 5 additions & 5 deletions .github/workflows/ci_truffleruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ jobs:
ports: ['5432:5432']
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: closure_tree
POSTGRES_DB: closure_tree_test
options: >-
--health-cmd pg_isready
Expand All @@ -45,10 +46,9 @@ jobs:
- activerecord_7.0
- activerecord_6.1
adapter:
- 'sqlite3:///:memory:'
- mysql2://root:root@0/closure_tree_test
- postgres://closure_tree:closure_tree@0/closure_tree_test

- 'sqlite3:///tmp/closure_tree_test.sqlite3'
- mysql2://root:[email protected]:3306/closure_tree_test
- postgres://closure_tree:closure_tree@localhost:5432/closure_tree_test
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -66,7 +66,7 @@ jobs:
- name: RSpec
env:
RAILS_VERSION: ${{ matrix.rails }}
DB_ADAPTER: ${{ matrix.adapter }}
DATABASE_URL: ${{ matrix.adapter }}
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
WITH_ADVISORY_LOCK_PREFIX: ${{ github.run_id }}
run: bin/rake
6 changes: 0 additions & 6 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,3 @@ source 'https://rubygems.org'

gemspec

platform :mri do
group :development do
gem 'bump', '~> 0.10.0'
gem 'github_changelog_generator', '~> 1.16'
end
end
14 changes: 1 addition & 13 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ RSpec::Core::RakeTask.new(:spec) do |task|
task.pattern = 'spec/closure_tree/*_spec.rb'
end

task default: %i[spec test]

namespace :spec do
desc 'Run all spec variants'
task :all do
Expand All @@ -29,14 +27,4 @@ Rake::TestTask.new do |t|
t.verbose = true
end

if RUBY_ENGINE == 'ruby'
require 'github_changelog_generator/task'
GitHubChangelogGenerator::RakeTask.new :changelog do |config|
config.user = 'ClosureTree'
config.project = 'closure_tree'
config.issues = false
config.future_release = '5.2.0'
config.since_tag = 'v7.4.0'
end
end
task default: 'spec:all'
task default: %i[spec:all test]
Loading