diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7f907097..7cfc9a10 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: strategy: fail-fast: false matrix: - ruby: ['2.7'] + ruby: ['2.7', '3.3'] steps: - name: Checkout diff --git a/.rubocop.yml b/.rubocop.yml index 4d06aa98..9c5e0819 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -11,6 +11,7 @@ AllCops: - 'spec/fixtures/**/*' - 'tmp/**/*' - 'spec/integration/**/*' + - 'Guardfile' NewCops: enable Metrics/BlockLength: diff --git a/Gemfile b/Gemfile index 0998ee0d..10daacfe 100644 --- a/Gemfile +++ b/Gemfile @@ -8,7 +8,6 @@ gem 'rake', require: false group :development do gem 'bump' gem 'mg', require: false - gem 'travis', require: false platforms :mri, :mingw do gem 'yard', require: false end @@ -29,7 +28,6 @@ group :development, :test do gem 'coveralls' gem 'overcommit' - gem 'ruby_dep', '1.5.0' platforms :mri, :mingw do gem 'pry', require: false @@ -38,6 +36,5 @@ group :development, :test do end group :test do - gem 'files', require: false gem 'git', require: false end diff --git a/spec/lib/annotate/annotate_models_spec.rb b/spec/lib/annotate/annotate_models_spec.rb index 09647461..e62a3244 100644 --- a/spec/lib/annotate/annotate_models_spec.rb +++ b/spec/lib/annotate/annotate_models_spec.rb @@ -3,7 +3,7 @@ require 'annotate/annotate_models' require 'annotate/active_record_patch' require 'active_support/core_ext/string' -require 'files' +require 'pathname' require 'tmpdir' describe AnnotateModels do @@ -2014,18 +2014,16 @@ def mock_column(name, type, options = {}) context 'when `model_dir` is valid' do let(:model_dir) do - Files do - file 'foo.rb' - dir 'bar' do - file 'baz.rb' - dir 'qux' do - file 'quux.rb' - end - end - dir 'concerns' do - file 'corge.rb' - end - end + dir = Pathname(Dir.mktmpdir('annotate_models')) + dir.join('bar').mkdir + dir.join('bar', 'qux').mkdir + dir.join('concerns').mkdir + + dir.join('foo.rb').write('') + dir.join('bar', 'baz.rb').write('') + dir.join('bar', 'qux', 'quux.rb').write('') + dir.join('concerns', 'corge.rb').write('') + dir end context 'when the model files are not specified' do