File tree Expand file tree Collapse file tree 6 files changed +116
-11
lines changed Expand file tree Collapse file tree 6 files changed +116
-11
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ name : Tests 
3+ 
4+ on :
5+   push :
6+     branches : [ "master" ] 
7+   pull_request :
8+     branches : [ "**" ] 
9+ 
10+ jobs :
11+   test :
12+     runs-on : ubuntu-20.04 
13+ 
14+     services :
15+       postgres :
16+         image : " postgres:13" 
17+         ports : ["5432:5432"] 
18+         env :
19+           POSTGRES_PASSWORD : postgres 
20+           POSTGRES_DB : closure_tree 
21+         options : >- 
22+           --health-cmd pg_isready 
23+           --health-interval 10s 
24+           --health-timeout 5s 
25+           --health-retries 5 
26+ 
27+ strategy :
28+       fail-fast : false 
29+       matrix :
30+         ruby :
31+           - " 3.2.5" 
32+         rails :
33+           - activerecord_7.0 
34+         adapter :
35+           - sqlite3 
36+           - mysql2 
37+           - postgresql 
38+ 
39+     steps :
40+       - name : Checkout 
41+         uses : actions/checkout@v4 
42+ 
43+       - name : Setup Ruby 
44+         uses : ruby/setup-ruby@v1 
45+         with :
46+           ruby-version : ${{ matrix.ruby }} 
47+ 
48+       - name : Set DB Adapter 
49+         env :
50+           RAILS_VERSION : ${{ matrix.rails }} 
51+           DB_ADAPTER : ${{ matrix.adapter }} 
52+ 
53+         #  See: https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-README.md#mysql
54+         run : | 
55+           if [ "${DB_ADAPTER}" = "mysql2" ]; then 
56+             sudo systemctl start mysql.service 
57+             mysql -u root -proot -e "create database closure_tree;" 
58+           fi 
59+ 
60+ name : Bundle 
61+         env :
62+           RAILS_VERSION : ${{ matrix.rails }} 
63+           DB_ADAPTER : ${{ matrix.adapter }} 
64+           BUNDLE_GEMFILE : gemfiles/${{ matrix.rails }}.gemfile 
65+         run : | 
66+           gem install bundler 
67+           bundle config path vendor/bundle 
68+           bundle install --jobs 4 --retry 3 
69+ 
70+ name : RSpec 
71+         env :
72+           RAILS_VERSION : ${{ matrix.rails }} 
73+           DB_ADAPTER : ${{ matrix.adapter }} 
74+           BUNDLE_GEMFILE : gemfiles/${{ matrix.rails }}.gemfile 
75+           WITH_ADVISORY_LOCK_PREFIX : ${{ github.run_id }} 
76+         run : bin/rake --trace spec:all 
Original file line number Diff line number Diff line change @@ -89,6 +89,21 @@ appraise 'activerecord-6.1' do
8989  end 
9090end 
9191
92+ appraise  'activerecord-7.0'  do 
93+   gem  'activerecord' ,  '~> 7.0' 
94+   platforms  :ruby  do 
95+     gem  'mysql2' 
96+     gem  'pg' 
97+     gem  'sqlite3' 
98+   end 
99+ 
100+   platforms  :jruby  do 
101+     gem  'activerecord-jdbcmysql-adapter' 
102+     gem  'activerecord-jdbcpostgresql-adapter' 
103+     gem  'activerecord-jdbcsqlite3-adapter' 
104+   end 
105+ end 
106+ 
92107appraise  'activerecord-edge'  do 
93108  gem  'activerecord' ,  github : 'rails/rails' 
94109  platforms  :ruby  do 
Original file line number Diff line number Diff line change @@ -26,12 +26,3 @@ namespace :spec do
2626    task . pattern  =  'spec/generators/*_spec.rb' 
2727  end 
2828end 
29- 
30- require  'github_changelog_generator/task' 
31- GitHubChangelogGenerator ::RakeTask . new  :changelog  do  |config |
32-   config . user  =  'ClosureTree' 
33-   config . project  =  'closure_tree' 
34-   config . issues  =  false 
35-   config . future_release  =  '5.2.0' 
36-   config . since_tag  =  'v7.3.0' 
37- end 
Original file line number Diff line number Diff line change 1+ # This file was generated by Appraisal
2+ 
3+ source "https://rubygems.org"
4+ 
5+ gem "bump", "~> 0.10.0"
6+ gem "github_changelog_generator", "~> 1.16"
7+ gem "activerecord", "~> 7.0"
8+ 
9+ platforms :ruby do
10+   gem "mysql2"
11+   gem "pg"
12+   gem "sqlite3"
13+ end
14+ 
15+ platforms :jruby do
16+   gem "activerecord-jdbcmysql-adapter"
17+   gem "activerecord-jdbcpostgresql-adapter"
18+   gem "activerecord-jdbcsqlite3-adapter"
19+ end
20+ 
21+ gemspec path: "../"
Original file line number Diff line number Diff line change @@ -78,7 +78,7 @@ class ContractType < ActiveRecord::Base
7878  has_many  :contracts ,  inverse_of : :contract_type 
7979end 
8080
81- class  Block  < ApplicationRecord 
81+ class  Block  < ActiveRecord :: Base 
8282  acts_as_tree  order : :column_whereby_ordering_is_inferred ,  # <- symbol, and not "sort_order" 
8383               numeric_order : true , 
8484               dependent : :destroy , 
Original file line number Diff line number Diff line change 3030  add_foreign_key ( :tag_hierarchies ,  :tags ,  :column  =>  'descendant_id' ) 
3131
3232  create_table  "uuid_tags" ,  :id  =>  false  do  |t |
33-     t . string  "uuid" ,   :unique   =>   true 
33+     t . string  "uuid" 
3434    t . string  "name" 
3535    t . string  "title" 
3636    t . string  "parent_uuid" 
3737    t . integer  "sort_order" 
3838    t . timestamps  null : false 
3939  end 
4040
41+   add_index  "uuid_tags" ,  :uuid ,  unique : true 
42+ 
4143  create_table  "uuid_tag_hierarchies" ,  :id  =>  false  do  |t |
4244    t . string  "ancestor_id" ,  :null  =>  false 
4345    t . string  "descendant_id" ,  :null  =>  false 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments