rasti-db 1.3.1 → 1.4.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
  SHA256:
3
- metadata.gz: 758ff6be9c26ae460399f8fb269d691171946224f69c997aec034bde72b50696
4
- data.tar.gz: 03aa1fa34277323614c92f9b52aaa361b72ae45d3fd2e40a8e81a33576ca0094
3
+ metadata.gz: ed5332eda8adfde54d7465d8f3f631d9b542f54d17c78644703d2f9054cb1bca
4
+ data.tar.gz: 5452a867c32c4083f10149c3496093e731d6f8d64a6b13fafd57ebcc0d7e38c8
5
5
  SHA512:
6
- metadata.gz: 5f09539fb3eacc3742a553d4d7e28a61c6d4afa26d13de48b187f5ea90d20c46336895c7094cacb4cc945cccd5b9fdd014ed47d7a9569087c8cb6b1e2ca26ffc
7
- data.tar.gz: 3a5f2850607db4477cb34c18fea8e719ab7b20b0e350eb7a814c973ccb714e37f6d19c7dcb549fe56878b942c755a0606fe4841413346c3eb8e0b8d1e9814305
6
+ metadata.gz: 31a039adaeb64c98fa7f5c38b2155a009f78e2a824d9c8d4e9969bd2d9ff7599afc899d5b10c3864694a22540061cf0f439f681792f2f89e9eb9da030aa7c28e
7
+ data.tar.gz: 393c7b91108ff8ab2c8effed2016b4ea912747baf65194c05614a01ef9d4d4447d41f350e996f0bdf8b14b9de102ced09bd023ce9cef590306068c28a8ae051c
@@ -4,10 +4,11 @@ rvm:
4
4
  - 2.0
5
5
  - 2.1
6
6
  - 2.2
7
- - 2.3.0
8
- - 2.4.0
9
- - 2.5.0
10
- - 2.6.0
7
+ - 2.3
8
+ - 2.4
9
+ - 2.5
10
+ - 2.6
11
+ - 2.7
11
12
  - jruby-9.1.7.0
12
13
  - jruby-9.1.16.0
13
14
  - ruby-head
@@ -20,8 +21,4 @@ matrix:
20
21
  - rvm: jruby-head
21
22
 
22
23
  jdk:
23
- - openjdk8
24
-
25
- before_install:
26
- - rvm all-gemsets do gem uninstall bundler -ax || true
27
- - gem install bundler -v "< 2"
24
+ - openjdk8
@@ -62,6 +62,10 @@ module Rasti
62
62
  @attributes = attributes
63
63
  end
64
64
 
65
+ def merge(new_attributes)
66
+ self.class.new attributes.merge(new_attributes)
67
+ end
68
+
65
69
  def eql?(other)
66
70
  instance_of?(other.class) && to_h.eql?(other.to_h)
67
71
  end
@@ -1,5 +1,5 @@
1
1
  module Rasti
2
2
  module DB
3
- VERSION = '1.3.1'
3
+ VERSION = '1.4.0'
4
4
  end
5
5
  end
@@ -25,7 +25,6 @@ Gem::Specification.new do |spec|
25
25
  spec.add_runtime_dependency 'class_config', '~> 0.0', '>= 0.0.2'
26
26
  spec.add_runtime_dependency 'multi_require', '~> 1.0'
27
27
 
28
- spec.add_development_dependency 'bundler', '~> 1.12'
29
28
  spec.add_development_dependency 'rake', '~> 11.0'
30
29
  spec.add_development_dependency 'minitest', '~> 5.0', '< 5.11'
31
30
  spec.add_development_dependency 'minitest-colorin', '~> 0.1'
@@ -79,4 +79,10 @@ describe 'Model' do
79
79
  refute_equal User.new(id: 1, name: 'User 1').hash, User.new(id: 2, name: 'User 2').hash
80
80
  end
81
81
 
82
+ it 'Merge' do
83
+ user = User.new(id: 1, name: 'User 1')
84
+ changed_user = user.merge(name: 'User 2')
85
+ changed_user.must_equal User.new(id: 1, name: 'User 2')
86
+ end
87
+
82
88
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rasti-db
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gabriel Naiman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-02 00:00:00.000000000 Z
11
+ date: 2020-01-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sequel
@@ -112,20 +112,6 @@ dependencies:
112
112
  - - "~>"
113
113
  - !ruby/object:Gem::Version
114
114
  version: '1.0'
115
- - !ruby/object:Gem::Dependency
116
- name: bundler
117
- requirement: !ruby/object:Gem::Requirement
118
- requirements:
119
- - - "~>"
120
- - !ruby/object:Gem::Version
121
- version: '1.12'
122
- type: :development
123
- prerelease: false
124
- version_requirements: !ruby/object:Gem::Requirement
125
- requirements:
126
- - - "~>"
127
- - !ruby/object:Gem::Version
128
- version: '1.12'
129
115
  - !ruby/object:Gem::Dependency
130
116
  name: rake
131
117
  requirement: !ruby/object:Gem::Requirement