glebtv-mongoid_nested_set 0.5.3 → 0.6.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: e4bbc837da8191ec439a50dac4aada31c25a3108
4
- data.tar.gz: 2b8bcbccc169e543ddd1c9bd4bb6534a05f0cdf2
3
+ metadata.gz: ff3955c3d64d7f85008ebda5e4776e56ec4adacb
4
+ data.tar.gz: 38c3737fca898de7a8ad033b4b9bb631c27546d2
5
5
  SHA512:
6
- metadata.gz: 594c32953884950e05426f8ddf4aa1abd6095259303a9a5a7be9119992f602181579f92d922e52befb84b60aed92224b8ece7d10644c6d06f0c830cb0f5a6a85
7
- data.tar.gz: ae0ae8f2280e304b43e9bba7333a6e754b519597abac0c296eba52a0f4dac6f39ef15c4dc55aacea69192cd55a03c272c6e6f8cf272133c30984595c55775318
6
+ metadata.gz: ac8821aead3b13fb5888f1efa9fed6fe1654c686657977569fdccc4ddfb23361be71d69d5991ce1579acbc25e7ecdac257ef2ff549fd60b87a18d8d66ae03afb
7
+ data.tar.gz: 920ffbaf9362ac74f37d9c6dc77fb29773e47d01fa9b2f5bc07ff97ef72931e26de2002019339d945b0cc386f98b6d8aae73825b3c7ae211432300d877c062c9
data/.travis.yml CHANGED
@@ -5,12 +5,5 @@ notifications:
5
5
  email: false
6
6
 
7
7
  rvm:
8
- - 1.9.3
9
- - 2.0.0
10
- - 2.1.0
11
- - jruby-20mode
8
+ - 2.3.3
12
9
 
13
- gemfile:
14
- - gemfiles/mongoid-3.1.gemfile
15
- - gemfiles/mongoid-4.0.gemfile
16
- - gemfiles/am-4.1.gemfile
@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
19
19
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
20
20
  s.require_paths = ["lib"]
21
21
 
22
- s.add_runtime_dependency 'mongoid', [">= 4.0.0", "< 6.1"]
22
+ s.add_runtime_dependency 'mongoid', [">= 6.0", "< 7.0"]
23
23
 
24
24
  s.add_development_dependency 'rake'
25
25
  s.add_development_dependency 'rspec'
@@ -47,7 +47,7 @@ module Mongoid::Acts::NestedSet
47
47
  field :depth, :type => Integer
48
48
 
49
49
  has_many :children, :class_name => self.name, :foreign_key => parent_field_name, :inverse_of => :parent, :order => left_field_name.to_sym.asc
50
- belongs_to :parent, :class_name => self.name, :foreign_key => parent_field_name
50
+ belongs_to :parent, :class_name => self.name, :foreign_key => parent_field_name, required: false, optional: true
51
51
 
52
52
  attr_accessor :skip_before_destroy
53
53
 
@@ -1,3 +1,3 @@
1
1
  module MongoidNestedSet
2
- VERSION = "0.5.3"
2
+ VERSION = "0.6.0"
3
3
  end
@@ -55,7 +55,9 @@ describe "A Mongoid::Document" do
55
55
  nodes.each_value do |node|
56
56
  # As soon as there is no upsert callbacks set
57
57
  # this is effectively identical to the straight driver call
58
- node.with(:collection => collection_name).upsert
58
+ node.with(:collection => collection_name) do |n|
59
+ n.upsert
60
+ end
59
61
  node.new_record = false
60
62
  end
61
63
  nodes
data/spec/spec_helper.rb CHANGED
@@ -20,7 +20,7 @@ if ENV['COVERAGE'] == 'yes'
20
20
  end
21
21
 
22
22
  SimpleCov.formatter = SimpleCov::Formatter::MergedFormatter
23
- SimpleCov.start
23
+ SimpleCov.start
24
24
  end
25
25
 
26
26
  Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glebtv-mongoid_nested_set
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GlebTV
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-07-01 00:00:00.000000000 Z
12
+ date: 2017-03-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: mongoid
@@ -17,20 +17,20 @@ dependencies:
17
17
  requirements:
18
18
  - - ">="
19
19
  - !ruby/object:Gem::Version
20
- version: 4.0.0
20
+ version: '6.0'
21
21
  - - "<"
22
22
  - !ruby/object:Gem::Version
23
- version: '6.1'
23
+ version: '7.0'
24
24
  type: :runtime
25
25
  prerelease: false
26
26
  version_requirements: !ruby/object:Gem::Requirement
27
27
  requirements:
28
28
  - - ">="
29
29
  - !ruby/object:Gem::Version
30
- version: 4.0.0
30
+ version: '6.0'
31
31
  - - "<"
32
32
  - !ruby/object:Gem::Version
33
- version: '6.1'
33
+ version: '7.0'
34
34
  - !ruby/object:Gem::Dependency
35
35
  name: rake
36
36
  requirement: !ruby/object:Gem::Requirement
@@ -210,7 +210,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
210
210
  version: '0'
211
211
  requirements: []
212
212
  rubyforge_project: mongoid_nested_set
213
- rubygems_version: 2.5.1
213
+ rubygems_version: 2.6.10
214
214
  signing_key:
215
215
  specification_version: 4
216
216
  summary: Nested set based tree implementation for Mongoid