active_record_mysql_xverify 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8633a85faba0ec2354e9d7e0b458ca5b93af15ae13fae736ad823aad6c493b43
4
- data.tar.gz: ab101f59d1c6d9e2a2211c4d62768ad86612b58c88f578f4c656bc3d83178293
3
+ metadata.gz: 2b9b9ce1ade186050ccfa538360ab9e4f05309b65a2d2fcc6e5d70532b95bf4e
4
+ data.tar.gz: 5eebab1a79aa13eb7dbc8d2c697495ca4dac550ceda70046698b7c89b6891f69
5
5
  SHA512:
6
- metadata.gz: bd0857e1d6cc99d26d6e35bd1b33e1c3ff24fe535f635e2e2b76efc80d8edb93f4b6e638311bb011c64b54ed91edb6a0f4de11359c477817be7331528517d21d
7
- data.tar.gz: edc43d517bb4c7b527ec82a5f662ec45c4618ab8684cd056f0a9f41338273dfd871b954fb33530497edec7078620a2808c028c626e251411254e5ac51ea7de73
6
+ metadata.gz: 783496ec07fe44f10c594a901cd46364add2257d4cee9cc4fc195567b54c28c0d5caf5d775f945d2e3f793a80e377b1bd64136b9080cb939c5cf34e3c9a7f861
7
+ data.tar.gz: e5b1a46379a954bc2bbc7a220237d283a5a40b0328caec95edcb026a1052c5d76be52213b6a3bbb9338b30c6a846b8a54657013cab66e60290af81b2a22c4895
data/.gitignore CHANGED
@@ -7,6 +7,7 @@
7
7
  /spec/reports/
8
8
  /tmp/
9
9
  /test.rb
10
+ /Gemfile.lock
10
11
 
11
12
  # rspec failure tracking
12
13
  .rspec_status
data/.rubocop.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  AllCops:
2
2
  Exclude:
3
3
  - 'gemfiles/**/*'
4
- TargetRubyVersion: 2.2
4
+ TargetRubyVersion: 2.3
5
5
  Metrics/BlockLength:
6
6
  Enabled: false
7
7
  Metrics/LineLength:
data/.travis.yml CHANGED
@@ -4,9 +4,10 @@ sudo: required
4
4
  language: ruby
5
5
  cache: bundler
6
6
  rvm:
7
- - 2.3.6
8
- - 2.4.4
9
- - 2.5.1
7
+ - 2.3.8
8
+ - 2.4.6
9
+ - 2.5.3
10
+ - 2.6.3
10
11
  before_install:
11
12
  - docker-compose up -d
12
13
  - function mysql_ping { mysqladmin -u root -h 127.0.0.1 -P 6033 ping > /dev/null 2> /dev/null; }
data/Appraisals CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  appraise 'ar42' do
2
4
  gem 'activerecord', '~> 4.2.10'
3
5
  gem 'mysql2', '< 0.5'
data/Gemfile CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source 'https://rubygems.org'
2
4
 
3
5
  git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
data/README.md CHANGED
@@ -128,3 +128,11 @@ Processing by ItemsController#update as */*
128
128
  Redirected to http://localhost:3000/items/1
129
129
  Completed 302 Found in 150ms (ActiveRecord: 145.2ms)
130
130
  ```
131
+
132
+ ## Test
133
+
134
+ ```
135
+ bundle install
136
+ docker-compose up -d
137
+ bundle exec rake
138
+ ```
data/Rakefile CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'bundler/gem_tasks'
2
4
  require 'rspec/core/rake_task'
3
5
  require 'rubocop/rake_task'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  lib = File.expand_path('lib', __dir__)
2
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
5
  require 'active_record_mysql_xverify/version'
data/bin/console CHANGED
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
2
3
 
3
4
  require 'bundler/setup'
4
5
  require 'activerecord_mysql_xverify'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'logger'
2
4
  require 'active_support'
3
5
  require 'active_record_mysql_xverify/version'
@@ -12,6 +14,6 @@ require 'active_record_mysql_xverify/verifiers/aurora_master'
12
14
  ActiveSupport.on_load :active_record do
13
15
  require 'active_record/connection_adapters/abstract_mysql_adapter'
14
16
  require 'active_record/connection_adapters/mysql2_adapter'
15
- ActiveRecord::ConnectionAdapters::Mysql2Adapter.prepend ActiveRecordMysqlXverify::ErrorHandler
17
+ ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter.prepend ActiveRecordMysqlXverify::ErrorHandler
16
18
  ActiveRecord::ConnectionAdapters::Mysql2Adapter.prepend ActiveRecordMysqlXverify::Verifier
17
19
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  @config = {
3
5
  handle_if: ->(_) { true },
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
- EXTEND_VERIFY_FLAG = "#{ActiveRecordMysqlXverify}_EXTEND_VERIFY_FLAG".freeze
4
+ EXTEND_VERIFY_FLAG = "#{ActiveRecordMysqlXverify}_EXTEND_VERIFY_FLAG"
3
5
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  module ErrorHandler
3
5
  def execute(*)
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  class << self
3
5
  def logger
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  module Utils
3
5
  class << self
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  module Verifier
3
5
  def active?
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
4
  module Verifiers
3
5
  AURORA_MASTER = lambda do |conn|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module ActiveRecordMysqlXverify
2
- VERSION = '0.1.0'.freeze
4
+ VERSION = '0.1.1'
3
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_record_mysql_xverify
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - winebarrel
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-11-19 00:00:00.000000000 Z
11
+ date: 2019-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -122,7 +122,6 @@ files:
122
122
  - ".travis.yml"
123
123
  - Appraisals
124
124
  - Gemfile
125
- - Gemfile.lock
126
125
  - LICENSE.txt
127
126
  - README.md
128
127
  - Rakefile
@@ -164,7 +163,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
164
163
  version: '0'
165
164
  requirements: []
166
165
  rubyforge_project:
167
- rubygems_version: 2.7.6
166
+ rubygems_version: 2.7.6.2
168
167
  signing_key:
169
168
  specification_version: 4
170
169
  summary: It is a library that performs extended verification when an error occurs
data/Gemfile.lock DELETED
@@ -1,81 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- active_record_mysql_xverify (0.1.0)
5
- activerecord
6
- mysql2
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- activemodel (5.2.1)
12
- activesupport (= 5.2.1)
13
- activerecord (5.2.1)
14
- activemodel (= 5.2.1)
15
- activesupport (= 5.2.1)
16
- arel (>= 9.0)
17
- activesupport (5.2.1)
18
- concurrent-ruby (~> 1.0, >= 1.0.2)
19
- i18n (>= 0.7, < 2)
20
- minitest (~> 5.1)
21
- tzinfo (~> 1.1)
22
- appraisal (2.2.0)
23
- bundler
24
- rake
25
- thor (>= 0.14.0)
26
- arel (9.0.0)
27
- ast (2.4.0)
28
- concurrent-ruby (1.1.3)
29
- diff-lcs (1.3)
30
- i18n (1.1.1)
31
- concurrent-ruby (~> 1.0)
32
- jaro_winkler (1.5.1)
33
- minitest (5.11.3)
34
- mysql2 (0.5.2)
35
- parallel (1.12.1)
36
- parser (2.5.3.0)
37
- ast (~> 2.4.0)
38
- powerpack (0.1.2)
39
- rainbow (3.0.0)
40
- rake (10.5.0)
41
- rspec (3.8.0)
42
- rspec-core (~> 3.8.0)
43
- rspec-expectations (~> 3.8.0)
44
- rspec-mocks (~> 3.8.0)
45
- rspec-core (3.8.0)
46
- rspec-support (~> 3.8.0)
47
- rspec-expectations (3.8.2)
48
- diff-lcs (>= 1.2.0, < 2.0)
49
- rspec-support (~> 3.8.0)
50
- rspec-mocks (3.8.0)
51
- diff-lcs (>= 1.2.0, < 2.0)
52
- rspec-support (~> 3.8.0)
53
- rspec-support (3.8.0)
54
- rubocop (0.60.0)
55
- jaro_winkler (~> 1.5.1)
56
- parallel (~> 1.10)
57
- parser (>= 2.5, != 2.5.1.1)
58
- powerpack (~> 0.1)
59
- rainbow (>= 2.2.2, < 4.0)
60
- ruby-progressbar (~> 1.7)
61
- unicode-display_width (~> 1.4.0)
62
- ruby-progressbar (1.10.0)
63
- thor (0.20.0)
64
- thread_safe (0.3.6)
65
- tzinfo (1.2.5)
66
- thread_safe (~> 0.1)
67
- unicode-display_width (1.4.0)
68
-
69
- PLATFORMS
70
- ruby
71
-
72
- DEPENDENCIES
73
- active_record_mysql_xverify!
74
- appraisal
75
- bundler
76
- rake
77
- rspec (~> 3.0)
78
- rubocop
79
-
80
- BUNDLED WITH
81
- 1.17.1