rubocop-sequel 0.0.3 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 99216f84e94571925e6df4de178faa3e7a975537
4
- data.tar.gz: 06af354421c2f03548d987462291701cf24d3bc7
2
+ SHA256:
3
+ metadata.gz: 8b48c970ba23412aca37456e02bc2e3cd27856338494132bfe0ef2e43fe2bf0b
4
+ data.tar.gz: 55f74cf994978072f005b0c23603e12d2eb79a9cb680f49496aaf430500ee2fe
5
5
  SHA512:
6
- metadata.gz: edca05f5886e960846934b535457e4e5b0c6289739342f06b63526fdf5d72ce080973794c9ac5c1e0d88ed07f9ad9eca2d086d75e2c04af4334eeecf4ac8aebc
7
- data.tar.gz: 4dfc24bd0ce158240d946a2951a052d12047c6ba1cdba6d116a988986ff9714d154efd550eee75046a36899f9dbc881c0462bd6ab4105df9dc49a83547d7a940
6
+ metadata.gz: '069b933d71802921ffdbf4e763686c00f69104ec6b181c1854f259e4bb9a13352ed39ccc76197341bc39487908eed2eecfd3d9e1ea1bd3453441de3a45f4f774'
7
+ data.tar.gz: c6273c16039bf43725eaa6218881fcd84c64835fcae46dc18393d15e32bb944a69252800d312f2a0f23b5d29aeb81c8ac28468ed3f5620cbfa1aa605731532c0
@@ -0,0 +1,30 @@
1
+ name: CI
2
+ on: [push, pull_request]
3
+
4
+ jobs:
5
+ main:
6
+ name: Ruby ${{ matrix.ruby }}
7
+ runs-on: ubuntu-latest
8
+ strategy:
9
+ matrix:
10
+ ruby:
11
+ - 2.4
12
+ - 2.5
13
+ - 2.6
14
+ - 2.7
15
+ - 3.0
16
+ steps:
17
+ - uses: actions/checkout@v2
18
+
19
+ - uses: ruby/setup-ruby@v1
20
+ with:
21
+ ruby-version: ${{ matrix.ruby }}
22
+
23
+ - name: Install gems
24
+ run: bundle install
25
+
26
+ - name: RuboCop
27
+ run: bundle exec rubocop --parallel
28
+
29
+ - name: RSpec
30
+ run: bundle exec rspec
@@ -0,0 +1,17 @@
1
+ require:
2
+ - rubocop-rspec
3
+
4
+ AllCops:
5
+ TargetRubyVersion: 2.4
6
+
7
+ # Offense count: 1
8
+ # Configuration parameters: CountComments, ExcludedMethods.
9
+ Metrics/BlockLength:
10
+ Exclude:
11
+ - spec/**/*
12
+
13
+ # Offense count: 1
14
+ # Configuration parameters: ExpectMatchingDefinition, Regex, IgnoreExecutableScripts, AllowedAcronyms.
15
+ Naming/FileName:
16
+ Exclude:
17
+ - 'lib/rubocop-sequel.rb'
data/Gemfile CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source 'https://rubygems.org'
2
4
 
3
5
  gemspec
data/README.md CHANGED
@@ -1,10 +1,12 @@
1
+ ![CI status](https://github.com/rubocop-hq/rubocop-sequel/workflows/CI/badge.svg)
2
+
1
3
  # RuboCop Sequel
2
4
 
3
- Code style checking for Sequel.
5
+ Code style checking for [Sequel](https://sequel.jeremyevans.net/).
4
6
 
5
7
  ## Installation
6
8
 
7
- Using the `rubocop-rspec` gem
9
+ Using the `rubocop-sequel` gem
8
10
 
9
11
  ```bash
10
12
  gem install rubocop-sequel
@@ -1,6 +1,9 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'rubocop'
2
4
 
3
5
  require 'rubocop/cop/sequel/column_default'
4
6
  require 'rubocop/cop/sequel/concurrent_index'
7
+ require 'rubocop/cop/sequel/json_column'
5
8
  require 'rubocop/cop/sequel/migration_name'
6
9
  require 'rubocop/cop/sequel/save_changes'
@@ -1,17 +1,20 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module RuboCop
2
4
  module Cop
3
5
  module Sequel
4
6
  # ColumnDefault looks for column creation with a default value.
5
- class ColumnDefault < Cop
6
- MSG = "Don't create new column with default values".freeze
7
+ class ColumnDefault < Base
8
+ MSG = "Don't create new column with default values"
7
9
 
8
- def_node_matcher :add_column_default, <<-MATCHER
10
+ def_node_matcher :add_column_default?, <<-MATCHER
9
11
  (send _ :add_column ... (hash (pair (sym :default) _)))
10
12
  MATCHER
11
13
 
12
14
  def on_send(node)
13
- return unless add_column_default(node)
14
- add_offense(node, location: :selector, message: MSG)
15
+ return unless add_column_default?(node)
16
+
17
+ add_offense(node.loc.selector, message: MSG)
15
18
  end
16
19
  end
17
20
  end
@@ -1,19 +1,19 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module RuboCop
2
4
  module Cop
3
5
  module Sequel
4
6
  # ConcurrentIndex looks for non-concurrent index creation.
5
- class ConcurrentIndex < Cop
6
- MSG = 'Prefer creating new index concurrently'.freeze
7
+ class ConcurrentIndex < Base
8
+ MSG = 'Prefer creating or dropping new index concurrently'
7
9
 
8
- def_node_matcher :add_index, <<-MATCHER
9
- (send _ :add_index $...)
10
+ def_node_matcher :indexes?, <<-MATCHER
11
+ (send _ {:add_index :drop_index} $...)
10
12
  MATCHER
11
13
 
12
14
  def on_send(node)
13
- add_index(node) do |args|
14
- if offensive?(args)
15
- add_offense(node, location: :selector, message: MSG)
16
- end
15
+ indexes?(node) do |args|
16
+ add_offense(node.loc.selector, message: MSG) if offensive?(args)
17
17
  end
18
18
  end
19
19
 
@@ -22,6 +22,7 @@ module RuboCop
22
22
  def offensive?(args)
23
23
  !args.last.hash_type? || args.last.each_descendant.none? do |n|
24
24
  next unless n.sym_type?
25
+
25
26
  n.children.any? { |s| s == :concurrently }
26
27
  end
27
28
  end
@@ -0,0 +1,40 @@
1
+ # frozen_string_literal: true
2
+
3
+ module RuboCop
4
+ module Cop
5
+ module Sequel
6
+ # JSONColumn looks for non-JSONB columns.
7
+ class JSONColumn < Base
8
+ MSG = 'Use JSONB rather than JSON or hstore'
9
+
10
+ def_node_matcher :json_or_hstore?, <<-MATCHER
11
+ (send _ :add_column ... (sym {:json :hstore}))
12
+ MATCHER
13
+
14
+ def_node_matcher :column_type?, <<-MATCHER
15
+ (send _ {:json :hstore} ...)
16
+ MATCHER
17
+
18
+ def_node_matcher :column_method?, <<-MATCHER
19
+ (send _ :column ... (sym {:json :hstore}))
20
+ MATCHER
21
+
22
+ def on_send(node)
23
+ return unless json_or_hstore?(node)
24
+
25
+ add_offense(node.loc.selector, message: MSG)
26
+ end
27
+
28
+ def on_block(node)
29
+ return unless node.send_node.method_name == :create_table
30
+
31
+ node.each_node(:send) do |method|
32
+ next unless column_method?(method) || column_type?(method)
33
+
34
+ add_offense(method.loc.selector, message: MSG)
35
+ end
36
+ end
37
+ end
38
+ end
39
+ end
40
+ end
@@ -1,18 +1,22 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module RuboCop
2
4
  module Cop
3
5
  module Sequel
4
6
  # MigrationName looks for migration files named with a default name.
5
- class MigrationName < Cop
6
- MSG = 'Migration files should not use default name.'.freeze
7
+ class MigrationName < Base
8
+ include RangeHelp
9
+
10
+ MSG = 'Migration files should not use default name.'
7
11
 
8
- def investigate(processed_source)
12
+ def on_new_investigation
9
13
  file_path = processed_source.buffer.name
10
14
  return if config.file_to_include?(file_path)
11
15
 
12
16
  return unless filename_bad?(file_path)
13
17
 
14
18
  location = source_range(processed_source.buffer, 1, 0)
15
- add_offense(nil, location: location)
19
+ add_offense(location)
16
20
  end
17
21
 
18
22
  private
@@ -1,22 +1,27 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module RuboCop
2
4
  module Cop
3
5
  module Sequel
4
6
  # SaveChanges promotes the use of save_changes.
5
- class SaveChanges < Cop
7
+ class SaveChanges < Base
8
+ extend AutoCorrector
9
+
6
10
  MSG = 'Use `Sequel::Model#save_changes` instead of '\
7
- '`Sequel::Model#save`.'.freeze
11
+ '`Sequel::Model#save`.'
8
12
 
9
- def_node_matcher :model_save, <<-MATCHER
13
+ def_node_matcher :model_save?, <<-MATCHER
10
14
  (send _ :save)
11
15
  MATCHER
12
16
 
13
17
  def on_send(node)
14
- return unless model_save(node)
15
- add_offense(node, location: :selector, message: MSG)
16
- end
18
+ return unless model_save?(node)
19
+
20
+ range = node.loc.selector
17
21
 
18
- def autocorrect(node)
19
- ->(corrector) { corrector.replace(node.loc.selector, 'save_changes') }
22
+ add_offense(range, message: MSG) do |corrector|
23
+ corrector.replace(range, 'save_changes')
24
+ end
20
25
  end
21
26
  end
22
27
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module RuboCop
2
4
  # RuboCop Sequel project namespace
3
5
  module Sequel
@@ -1,9 +1,11 @@
1
+ # frozen_string_literal: true
2
+
1
3
  Gem::Specification.new do |gem|
2
4
  gem.authors = ['Timothée Peignier']
3
5
  gem.email = ['timothee.peignier@tryphon.org']
4
6
  gem.description = 'Code style checking for Sequel'
5
- gem.summary = 'A plugin for the RuboCop code style & linting tool.'
6
- gem.homepage = 'http://rubygems.org/gems/rubocop-sequel'
7
+ gem.summary = 'A Sequel plugin for RuboCop'
8
+ gem.homepage = 'https://github.com/rubocop-hq/rubocop-sequel'
7
9
  gem.license = 'MIT'
8
10
 
9
11
  gem.files = `git ls-files`.split($OUTPUT_RECORD_SEPARATOR)
@@ -11,13 +13,16 @@ Gem::Specification.new do |gem|
11
13
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
12
14
  gem.name = 'rubocop-sequel'
13
15
  gem.require_paths = ['lib']
14
- gem.version = '0.0.3'
16
+ gem.version = '0.2.0'
17
+
18
+ gem.required_ruby_version = '>= 2.4'
15
19
 
16
- gem.add_runtime_dependency 'rubocop', '~> 0.52', '>= 0.52'
20
+ gem.add_runtime_dependency 'rubocop', '~> 1.0'
17
21
 
18
- gem.add_development_dependency 'rake', '~> 12.0.0', '>= 12.0.0'
19
- gem.add_development_dependency 'rspec', '~> 3.5', '>= 3.5.0'
20
- gem.add_development_dependency 'sequel', '~> 4.49', '>= 4.49.0'
21
- gem.add_development_dependency 'simplecov', '~> 0.12'
22
+ gem.add_development_dependency 'rake', '~> 12.3.0'
23
+ gem.add_development_dependency 'rspec', '~> 3.7'
24
+ gem.add_development_dependency 'rubocop-rspec', '~> 2.0'
25
+ gem.add_development_dependency 'sequel', '~> 4.49'
26
+ gem.add_development_dependency 'simplecov', '~> 0.16'
22
27
  gem.add_development_dependency 'sqlite3', '~> 1.3', '>= 1.3.12'
23
28
  end
@@ -1,15 +1,17 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'spec_helper'
2
4
 
3
5
  describe RuboCop::Cop::Sequel::ColumnDefault do
4
6
  subject(:cop) { described_class.new }
5
7
 
6
8
  it 'registers an offense when setting a default' do
7
- inspect_source('add_column(:products, :type, :text, default: "cop")')
8
- expect(cop.offenses.size).to eq(1)
9
+ offenses = inspect_source('add_column(:products, :type, :text, default: "cop")')
10
+ expect(offenses.size).to eq(1)
9
11
  end
10
12
 
11
13
  it 'does not register an offense when not setting a default' do
12
- inspect_source('add_column(:products, :type, :text)')
13
- expect(cop.offenses).to be_empty
14
+ offenses = inspect_source('add_column(:products, :type, :text)')
15
+ expect(offenses).to be_empty
14
16
  end
15
17
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'spec_helper'
2
4
 
3
5
  describe RuboCop::Cop::Sequel::ConcurrentIndex do
@@ -5,25 +7,35 @@ describe RuboCop::Cop::Sequel::ConcurrentIndex do
5
7
 
6
8
  context 'without the concurrent option' do
7
9
  it 'registers an offense without options' do
8
- inspect_source('add_index(:products, :name)')
9
- expect(cop.offenses.size).to eq(1)
10
+ offenses = inspect_source(<<~SOURCE)
11
+ add_index(:products, :name)
12
+ drop_index(:products, :name)
13
+ SOURCE
14
+ expect(offenses.size).to eq(2)
10
15
  end
11
16
 
12
17
  it 'registers an offense with other options' do
13
- inspect_source('add_index(:products, :name, unique: true)')
14
- expect(cop.offenses.size).to eq(1)
18
+ offenses = inspect_source(<<~SOURCE)
19
+ add_index(:products, :name, unique: true)
20
+ drop_index(:products, :name, unique: true)
21
+ SOURCE
22
+ expect(offenses.size).to eq(2)
15
23
  end
16
24
 
17
25
  it 'registers an offense with composite index' do
18
- inspect_source('add_index(:products, :name, unique: true)')
19
- expect(cop.offenses.size).to eq(1)
26
+ offenses = inspect_source(<<~SOURCE)
27
+ add_index(:products, [:name, :price], unique: true)
28
+ drop_index(:products, [:name, :price])
29
+ SOURCE
30
+ expect(offenses.size).to eq(2)
20
31
  end
21
32
  end
22
33
 
23
34
  it 'does not register an offense when using concurrent option' do
24
- inspect_source(
25
- 'add_index(:products, :name, unique: true, concurrently: true)'
26
- )
27
- expect(cop.offenses).to be_empty
35
+ offenses = inspect_source(<<~SOURCE)
36
+ add_index(:products, :name, unique: true, concurrently: true)
37
+ drop_index(:products, :name, concurrently: true)
38
+ SOURCE
39
+ expect(offenses).to be_empty
28
40
  end
29
41
  end
@@ -0,0 +1,51 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'spec_helper'
4
+
5
+ describe RuboCop::Cop::Sequel::JSONColumn do
6
+ subject(:cop) { described_class.new }
7
+
8
+ context 'with add_column' do
9
+ it 'registers an offense when using json type' do
10
+ offenses = inspect_source('add_column(:products, :type, :json)')
11
+ expect(offenses.size).to eq(1)
12
+ end
13
+
14
+ it 'registers an offense when using hstore type' do
15
+ offenses = inspect_source('add_column(:products, :type, :hstore)')
16
+ expect(offenses.size).to eq(1)
17
+ end
18
+
19
+ it 'does not register an offense when using jsonb' do
20
+ offenses = inspect_source('add_column(:products, :type, :jsonb)')
21
+ expect(offenses).to be_empty
22
+ end
23
+ end
24
+
25
+ context 'with create_table' do
26
+ it 'registers an offense when using json as a method' do
27
+ offenses = inspect_source('create_table(:products) { json :type, default: {} }')
28
+ expect(offenses.size).to eq(1)
29
+ end
30
+
31
+ it 'registers an offense when using the column method with hstore' do
32
+ offenses = inspect_source('create_table(:products) { column :type, :hstore }')
33
+ expect(offenses.size).to eq(1)
34
+ end
35
+
36
+ it 'does not register an offense when using jsonb as column type`' do
37
+ offenses = inspect_source('create_table(:products) { column :type, :jsonb }')
38
+ expect(offenses).to be_empty
39
+ end
40
+
41
+ it 'does not register an offense when using jsonb' do
42
+ offenses = inspect_source('create_table(:products) { jsonb :type }')
43
+ expect(offenses).to be_empty
44
+ end
45
+
46
+ it 'does not register an offense when using a simple type' do
47
+ offenses = inspect_source('create_table(:products) { integer :type, default: 0 }')
48
+ expect(offenses).to be_empty
49
+ end
50
+ end
51
+ end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'spec_helper'
2
4
 
3
5
  describe RuboCop::Cop::Sequel::MigrationName, :config do
@@ -11,17 +13,17 @@ describe RuboCop::Cop::Sequel::MigrationName, :config do
11
13
  )
12
14
  end
13
15
 
14
- context 'default configuration' do
16
+ context 'with default configuration' do
15
17
  let(:cop_config) { {} }
16
18
 
17
19
  it 'registers an offense when using the default name' do
18
- inspect_source('', 'new_migration.rb')
19
- expect(cop.offenses.size).to eq(1)
20
+ offenses = inspect_source('', 'new_migration.rb')
21
+ expect(offenses.size).to eq(1)
20
22
  end
21
23
 
22
24
  it 'does not register an offense when using a specific name' do
23
- inspect_source('', 'add_index.rb')
24
- expect(cop.offenses).to be_empty
25
+ offenses = inspect_source('', 'add_index.rb')
26
+ expect(offenses).to be_empty
25
27
  end
26
28
  end
27
29
 
@@ -29,13 +31,13 @@ describe RuboCop::Cop::Sequel::MigrationName, :config do
29
31
  let(:cop_config) { { 'DefaultName' => 'add_migration' } }
30
32
 
31
33
  it 'registers an offense when using the default name' do
32
- inspect_source('', 'add_migration.rb')
33
- expect(cop.offenses.size).to eq(1)
34
+ offenses = inspect_source('', 'add_migration.rb')
35
+ expect(offenses.size).to eq(1)
34
36
  end
35
37
 
36
38
  it 'does not register an offense when using a specific name' do
37
- inspect_source('', 'add_index.rb')
38
- expect(cop.offenses).to be_empty
39
+ offenses = inspect_source('', 'add_index.rb')
40
+ expect(offenses).to be_empty
39
41
  end
40
42
  end
41
43
  end
@@ -1,16 +1,18 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'spec_helper'
2
4
 
3
5
  describe RuboCop::Cop::Sequel::SaveChanges do
4
6
  subject(:cop) { described_class.new }
5
7
 
6
8
  it 'registers an offense when using save' do
7
- inspect_source('favorite.save')
8
- expect(cop.offenses.size).to eq(1)
9
+ offenses = inspect_source('favorite.save')
10
+ expect(offenses.size).to eq(1)
9
11
  end
10
12
 
11
13
  it 'does not register an offense when using save_changes' do
12
- inspect_source('favorite.save_changes')
13
- expect(cop.offenses).to be_empty
14
+ offenses = inspect_source('favorite.save_changes')
15
+ expect(offenses).to be_empty
14
16
  end
15
17
 
16
18
  it 'auto-corrects by using save_changes' do
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'rubocop'
2
4
  require 'rubocop/rspec/support'
3
5
  require 'rubocop-sequel'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubocop-sequel
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Timothée Peignier
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-19 00:00:00.000000000 Z
11
+ date: 2021-01-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,60 +16,56 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0.52'
20
- - - ">="
21
- - !ruby/object:Gem::Version
22
- version: '0.52'
19
+ version: '1.0'
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
24
  - - "~>"
28
25
  - !ruby/object:Gem::Version
29
- version: '0.52'
30
- - - ">="
31
- - !ruby/object:Gem::Version
32
- version: '0.52'
26
+ version: '1.0'
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: rake
35
29
  requirement: !ruby/object:Gem::Requirement
36
30
  requirements:
37
31
  - - "~>"
38
32
  - !ruby/object:Gem::Version
39
- version: 12.0.0
40
- - - ">="
41
- - !ruby/object:Gem::Version
42
- version: 12.0.0
33
+ version: 12.3.0
43
34
  type: :development
44
35
  prerelease: false
45
36
  version_requirements: !ruby/object:Gem::Requirement
46
37
  requirements:
47
38
  - - "~>"
48
39
  - !ruby/object:Gem::Version
49
- version: 12.0.0
50
- - - ">="
51
- - !ruby/object:Gem::Version
52
- version: 12.0.0
40
+ version: 12.3.0
53
41
  - !ruby/object:Gem::Dependency
54
42
  name: rspec
55
43
  requirement: !ruby/object:Gem::Requirement
56
44
  requirements:
57
45
  - - "~>"
58
46
  - !ruby/object:Gem::Version
59
- version: '3.5'
60
- - - ">="
61
- - !ruby/object:Gem::Version
62
- version: 3.5.0
47
+ version: '3.7'
63
48
  type: :development
64
49
  prerelease: false
65
50
  version_requirements: !ruby/object:Gem::Requirement
66
51
  requirements:
67
52
  - - "~>"
68
53
  - !ruby/object:Gem::Version
69
- version: '3.5'
70
- - - ">="
54
+ version: '3.7'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rubocop-rspec
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
71
60
  - !ruby/object:Gem::Version
72
- version: 3.5.0
61
+ version: '2.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '2.0'
73
69
  - !ruby/object:Gem::Dependency
74
70
  name: sequel
75
71
  requirement: !ruby/object:Gem::Requirement
@@ -77,9 +73,6 @@ dependencies:
77
73
  - - "~>"
78
74
  - !ruby/object:Gem::Version
79
75
  version: '4.49'
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: 4.49.0
83
76
  type: :development
84
77
  prerelease: false
85
78
  version_requirements: !ruby/object:Gem::Requirement
@@ -87,23 +80,20 @@ dependencies:
87
80
  - - "~>"
88
81
  - !ruby/object:Gem::Version
89
82
  version: '4.49'
90
- - - ">="
91
- - !ruby/object:Gem::Version
92
- version: 4.49.0
93
83
  - !ruby/object:Gem::Dependency
94
84
  name: simplecov
95
85
  requirement: !ruby/object:Gem::Requirement
96
86
  requirements:
97
87
  - - "~>"
98
88
  - !ruby/object:Gem::Version
99
- version: '0.12'
89
+ version: '0.16'
100
90
  type: :development
101
91
  prerelease: false
102
92
  version_requirements: !ruby/object:Gem::Requirement
103
93
  requirements:
104
94
  - - "~>"
105
95
  - !ruby/object:Gem::Version
106
- version: '0.12'
96
+ version: '0.16'
107
97
  - !ruby/object:Gem::Dependency
108
98
  name: sqlite3
109
99
  requirement: !ruby/object:Gem::Requirement
@@ -131,31 +121,32 @@ executables: []
131
121
  extensions: []
132
122
  extra_rdoc_files: []
133
123
  files:
124
+ - ".github/workflows/actions.yml"
134
125
  - ".gitignore"
135
126
  - ".rspec"
136
- - ".rubocop_todo.yml"
137
- - ".travis.yml"
127
+ - ".rubocop.yml"
138
128
  - Gemfile
139
129
  - LICENSE
140
130
  - README.md
141
131
  - lib/rubocop-sequel.rb
142
132
  - lib/rubocop/cop/sequel/column_default.rb
143
133
  - lib/rubocop/cop/sequel/concurrent_index.rb
134
+ - lib/rubocop/cop/sequel/json_column.rb
144
135
  - lib/rubocop/cop/sequel/migration_name.rb
145
136
  - lib/rubocop/cop/sequel/save_changes.rb
146
137
  - lib/rubocop/sequel.rb
147
138
  - rubocop-sequel.gemspec
148
- - rubocop.yml
149
139
  - spec/rubocop/cop/sequel/column_default_spec.rb
150
140
  - spec/rubocop/cop/sequel/concurrent_index_spec.rb
141
+ - spec/rubocop/cop/sequel/json_column_spec.rb
151
142
  - spec/rubocop/cop/sequel/migration_name_spec.rb
152
143
  - spec/rubocop/cop/sequel/save_changes_spec.rb
153
144
  - spec/spec_helper.rb
154
- homepage: http://rubygems.org/gems/rubocop-sequel
145
+ homepage: https://github.com/rubocop-hq/rubocop-sequel
155
146
  licenses:
156
147
  - MIT
157
148
  metadata: {}
158
- post_install_message:
149
+ post_install_message:
159
150
  rdoc_options: []
160
151
  require_paths:
161
152
  - lib
@@ -163,21 +154,21 @@ required_ruby_version: !ruby/object:Gem::Requirement
163
154
  requirements:
164
155
  - - ">="
165
156
  - !ruby/object:Gem::Version
166
- version: '0'
157
+ version: '2.4'
167
158
  required_rubygems_version: !ruby/object:Gem::Requirement
168
159
  requirements:
169
160
  - - ">="
170
161
  - !ruby/object:Gem::Version
171
162
  version: '0'
172
163
  requirements: []
173
- rubyforge_project:
174
- rubygems_version: 2.5.2
175
- signing_key:
164
+ rubygems_version: 3.1.4
165
+ signing_key:
176
166
  specification_version: 4
177
- summary: A plugin for the RuboCop code style & linting tool.
167
+ summary: A Sequel plugin for RuboCop
178
168
  test_files:
179
169
  - spec/rubocop/cop/sequel/column_default_spec.rb
180
170
  - spec/rubocop/cop/sequel/concurrent_index_spec.rb
171
+ - spec/rubocop/cop/sequel/json_column_spec.rb
181
172
  - spec/rubocop/cop/sequel/migration_name_spec.rb
182
173
  - spec/rubocop/cop/sequel/save_changes_spec.rb
183
174
  - spec/spec_helper.rb
@@ -1,13 +0,0 @@
1
- # This configuration was generated by
2
- # `rubocop --auto-gen-config`
3
- # on 2016-12-16 21:46:22 -0800 using RuboCop version 0.46.0.
4
- # The point is for the user to remove these configuration records
5
- # one by one as the offenses are removed from the code base.
6
- # Note that changes in the inspected code, or installation of new
7
- # versions of RuboCop, may require this file to be generated again.
8
-
9
- # Offense count: 1
10
- # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
11
- # URISchemes: http, https
12
- Metrics/LineLength:
13
- Max: 88
@@ -1,5 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - 2.3.3
4
- - 2.4.0
5
- script: bundle exec rspec spec
@@ -1,3 +0,0 @@
1
- inherit_from: .rubocop_todo.yml
2
- AllCops:
3
- TargetRubyVersion: 2.3