mongoid-compatibility 0.4.1 → 0.5.0

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: 88dc135cf15e9485c44ceccde2ec8b25a73184a8
4
- data.tar.gz: 739ea9e74d17368c4a49083adac7fec708cc49b4
3
+ metadata.gz: 4c9cc2a402a72a8af6bd7e28e93d8428605fe8c2
4
+ data.tar.gz: 8d3c8435aa36bcdca204a5f15bc59de675c94ec4
5
5
  SHA512:
6
- metadata.gz: 9b87667aee1355d87b5262e8efd5bbb53b1ff06ab11e3dedc30d0fff65cacb9577b4b4d7b4ac61eccb7d1b460c7eca504ace2fc41030f8a0bb756c7a5f930faf
7
- data.tar.gz: 39257d4303caa776fac3580b317946f9cc74679554a4b6cf756410029204b73dfc3368a93d47f718606f61c9feb7d7a89b7997da31e8b4bf834ea58c630d272e
6
+ metadata.gz: 227f291b3660311bad79c640fa6c278822698c65ecc397462a466a511128c61c6591a881dbb014481702d1b76dfe020aeb97fa6a0d4e1503cae8ee6ee3869e82
7
+ data.tar.gz: a28e3cb6ddabff170b99029529030b8dc46fee41bc11768acaca5fafcdf470d4e2af30b4ac69d2eb3ba56fdf4c4aaef4cfddfcee2dd55e5c1ea2f5ce329344c5
@@ -6,6 +6,9 @@ matrix:
6
6
  - rvm: 2.3.1
7
7
  script:
8
8
  - bundle exec danger
9
+ - rvm: 2.4.0
10
+ env:
11
+ - MONGOID_VERSION=7
9
12
  - rvm: 2.4.0
10
13
  env:
11
14
  - MONGOID_VERSION=6
@@ -1,3 +1,11 @@
1
+ ### 0.5.1 (Next)
2
+
3
+ * Your contribution here.
4
+
5
+ ### 0.5.0
6
+
7
+ * [#10](https://github.com/mongoid/mongoid-compatibility/pull/10): Compatibility with Mongoid 7.x - [@joeyAghion](https://github.com/joeyAghion).
8
+
1
9
  ### 0.4.1 (2017/01/19)
2
10
 
3
11
  * [#5](https://github.com/mongoid/mongoid-compatibility/pull/5): Compatibility with Ruby 2.4.0 and Mongoid 6.0 - [@moodlemags](https://github.com/moodlemags).
data/Gemfile CHANGED
@@ -5,6 +5,8 @@ gemspec
5
5
  case version = ENV['MONGOID_VERSION'] || '6.0'
6
6
  when 'HEAD'
7
7
  gem 'mongoid', github: 'mongodb/mongoid'
8
+ when /^7/
9
+ gem 'mongoid', github: 'mongodb/mongoid', branch: '7.0-dev'
8
10
  when /^6/
9
11
  gem 'mongoid', '~> 6.0'
10
12
  when /^5/
data/LICENSE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2015 Daniel Doubrovkine, Artsy and Contributors
3
+ Copyright (c) 2015-2017 Daniel Doubrovkine, Artsy and Contributors
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining
6
6
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -6,7 +6,7 @@ Mongoid::Compatibility
6
6
  [![Dependency Status](https://gemnasium.com/mongoid/mongoid-compatibility.svg)](https://gemnasium.com/mongoid/mongoid-compatibility)
7
7
  [![Code Climate](https://codeclimate.com/github/mongoid/mongoid-compatibility.svg)](https://codeclimate.com/github/mongoid/mongoid-compatibility)
8
8
 
9
- Compatibility helpers for Mongoid versions 2, 3, 4, and 5, and the **prerelease** version 6.
9
+ Compatibility helpers for Mongoid versions 2, 3, 4, 5, 6 and 7.
10
10
 
11
11
  ### Install
12
12
 
@@ -37,6 +37,9 @@ Mongoid::Compatibility::Version.mongoid5?
37
37
 
38
38
  Mongoid::Compatibility::Version.mongoid6?
39
39
  # => is this Mongoid 6.x?
40
+
41
+ Mongoid::Compatibility::Version.mongoid7?
42
+ # => is this Mongoid 7.x?
40
43
  ```
41
44
 
42
45
  #### Mongoid::Compatibility::ObjectId
@@ -52,6 +55,6 @@ See [CONTRIBUTING](CONTRIBUTING.md).
52
55
 
53
56
  ### Copyright and License
54
57
 
55
- Copyright Daniel Doubrovkine and Contributors, Artsy Inc., 2015
58
+ Copyright Daniel Doubrovkine and Contributors, Artsy Inc., 2015-2017
56
59
 
57
60
  [MIT License](LICENSE.md)
@@ -1,5 +1,5 @@
1
1
  module Mongoid
2
2
  module Compatibility
3
- VERSION = '0.4.1'.freeze
3
+ VERSION = '0.5.0'.freeze
4
4
  end
5
5
  end
@@ -2,7 +2,7 @@ module Mongoid
2
2
  module Compatibility
3
3
  module Version
4
4
  module ClassMethods
5
- (2..6).each do |v|
5
+ (2..7).each do |v|
6
6
  const_set "V#{v}", Mongoid::VERSION =~ Regexp.new("^#{v}\.")
7
7
 
8
8
  define_method "mongoid#{v}?" do
@@ -0,0 +1,8 @@
1
+ test:
2
+ clients:
3
+ default:
4
+ database: mongoid-compatibility
5
+ hosts:
6
+ - localhost:27017
7
+ options:
8
+ raise_not_found_error: false
@@ -12,7 +12,7 @@ describe Mongoid::Compatibility::Version do
12
12
  it 'defines version methods' do
13
13
  expect(Mongoid::Compatibility::Version.methods - Object.methods).to_not eq []
14
14
  end
15
- (2..6).each do |v|
15
+ (2..7).each do |v|
16
16
  context "mongoid #{v}" do
17
17
  it "responds to mongoid#{v}?" do
18
18
  expect(Mongoid::Compatibility::Version).to respond_to("mongoid#{v}?")
@@ -10,6 +10,8 @@ elsif Mongoid::Compatibility::Version.mongoid5?
10
10
  Mongoid.load! 'spec/config/mongoid5.yml'
11
11
  elsif Mongoid::Compatibility::Version.mongoid6?
12
12
  Mongoid.load! 'spec/config/mongoid6.yml'
13
+ elsif Mongoid::Compatibility::Version.mongoid7?
14
+ Mongoid.load! 'spec/config/mongoid7.yml'
13
15
  else
14
16
  fail "unsupported Mongoid version #{Mongoid::VERSION}"
15
17
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongoid-compatibility
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Doubrovkine
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-19 00:00:00.000000000 Z
11
+ date: 2017-09-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mongoid
@@ -69,6 +69,7 @@ files:
69
69
  - spec/config/mongoid4.yml
70
70
  - spec/config/mongoid5.yml
71
71
  - spec/config/mongoid6.yml
72
+ - spec/config/mongoid7.yml
72
73
  - spec/mongoid/compatibility/object_id_spec.rb
73
74
  - spec/mongoid/compatibility/self_spec.rb
74
75
  - spec/mongoid/compatibility/version_spec.rb
@@ -94,7 +95,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
94
95
  version: 1.3.6
95
96
  requirements: []
96
97
  rubyforge_project:
97
- rubygems_version: 2.6.8
98
+ rubygems_version: 2.5.2
98
99
  signing_key:
99
100
  specification_version: 4
100
101
  summary: Compatibility helpers for Mongoid.