activerecord-pedantmysql2-adapter 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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e590eeb3922b4dec13eb497568619d252decce72
|
4
|
+
data.tar.gz: 4fe690e1ea1684d749c0c97e0c9a7b6dc5bc1bdb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6808c691edaf9a7c01ee54180b5fc48a4fd4d390046c0898841a4645f8ff6bf7f0de62f10fd1a0a22b8531db42f3f30205a0f8bed97feb9c18059b50662fbed9
|
7
|
+
data.tar.gz: e1a521d2c7b817059695f6442839daaf77c66cb7208e06e6bac97ba255fbf59a4b9c04c034c649bde00ec21c7ec49d15b9d397ec2d114ef01cfbf6567a4c186f
|
@@ -16,7 +16,7 @@ module ActiveRecord
|
|
16
16
|
ActiveRecord::ConnectionAdapters::PedantMysql2Adapter.new(client, logger, options, config)
|
17
17
|
rescue Mysql2::Error => error
|
18
18
|
if error.message.include?("Unknown database") && defined?(ActiveRecord::NoDatabaseError)
|
19
|
-
raise ActiveRecord::NoDatabaseError.new(error.message
|
19
|
+
raise ActiveRecord::NoDatabaseError.new(error.message)
|
20
20
|
else
|
21
21
|
raise
|
22
22
|
end
|
data/shipit.rubygems.yml
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
|
1
|
+
fetch:
|
2
|
+
- fetch-gem-version activerecord-pedantmysql2-adapter Shopify/activerecord-pedantmysql2-adapter
|
@@ -0,0 +1,18 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
class Mock
|
4
|
+
include ActiveRecord::ConnectionHandling
|
5
|
+
def logger
|
6
|
+
nil
|
7
|
+
end
|
8
|
+
end
|
9
|
+
|
10
|
+
describe ActiveRecord::ConnectionHandling do
|
11
|
+
|
12
|
+
it 'raises NoDatabaseError correctly' do
|
13
|
+
expect {
|
14
|
+
Mock.new.pedant_mysql2_connection({host: 'localhost', database: 'nosuchthing'})
|
15
|
+
}.to raise_error(ActiveRecord::NoDatabaseError)
|
16
|
+
end
|
17
|
+
|
18
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-pedantmysql2-adapter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jean Boussier
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-08-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -130,6 +130,7 @@ files:
|
|
130
130
|
- lib/pedant_mysql2/version.rb
|
131
131
|
- shipit.rubygems.yml
|
132
132
|
- spec/adapter_spec.rb
|
133
|
+
- spec/connection_spec.rb
|
133
134
|
- spec/spec_helper.rb
|
134
135
|
- spec/support/database.rb
|
135
136
|
homepage: https://github.com/Shopify/activerecord-pedantmysql2-adapter
|
@@ -152,11 +153,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
152
153
|
version: '0'
|
153
154
|
requirements: []
|
154
155
|
rubyforge_project:
|
155
|
-
rubygems_version: 2.2.
|
156
|
+
rubygems_version: 2.2.2
|
156
157
|
signing_key:
|
157
158
|
specification_version: 4
|
158
159
|
summary: ActiveRecord adapter for MySQL that report warnings.
|
159
160
|
test_files:
|
160
161
|
- spec/adapter_spec.rb
|
162
|
+
- spec/connection_spec.rb
|
161
163
|
- spec/spec_helper.rb
|
162
164
|
- spec/support/database.rb
|