rumination 0.2.1 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 054a94bf28ce793d807ea500b8c35a597279e54a
4
- data.tar.gz: 0fa10ed9bd4f5bb882eb2008de46c2f08d8d543b
3
+ metadata.gz: fc7916abb449d462bb96d6f87cba350b4a76bc8b
4
+ data.tar.gz: e85b761e383a650b48b845ea2815b1d81db95075
5
5
  SHA512:
6
- metadata.gz: 26e0c6a4f94cb6bbe91010a945b29610a7bca6fd27fdef1af467f96cd8ac7f7fa49ca98f8c0111eac37a4f766ba14abbab3b7ae2ca1fa77ccf940873936c8d6c
7
- data.tar.gz: e619327885c56f6308e4770e9feb34964008ff04d11dcedc99df8b9f72fba09df5f05204b4cb37717b47273fea2d82faca7a0815568b5d9225d423f6e483e42d
6
+ metadata.gz: 6904747a2e39b33a26174e0d18a3b35356bbce6a4bc3572743cffe3f57159979e1cb5f46529594aa22a1bf0c1c62c9768f10f54f08e7dad4145c108e39155ae9
7
+ data.tar.gz: 8d97d58efefb15e01d4c4efa3b5d131957421f700e2b41d3f56d65cffbd8086ce39a50e1d3d88f612587c129eb7c15f220d344286f781634f87b35e6271331e6
@@ -2,8 +2,10 @@ require "active_model"
2
2
 
3
3
  module Rumination
4
4
  class DevUser
5
- CannotBeInitialized = Class.new(RuntimeError)
6
5
  include ActiveModel::Model
6
+ include ActiveModel::Serialization
7
+
8
+ CannotBeInitialized = Class.new(RuntimeError)
7
9
  attr_accessor :name, :host, :password, :email
8
10
 
9
11
  def initialize args={}
@@ -17,5 +19,14 @@ module Rumination
17
19
  raise CannotBeInitialized, "Can't guess dev user email" unless self.email.present? || self.host.present?
18
20
  self.email ||= [name, host].join("@")
19
21
  end
22
+
23
+ def attributes
24
+ {
25
+ "name" => nil,
26
+ "password" => nil,
27
+ "host" => nil,
28
+ "email" => nil,
29
+ }
30
+ end
20
31
  end
21
32
  end
@@ -1,3 +1,3 @@
1
1
  module Rumination
2
- VERSION = "0.2.1"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rumination
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Artem Baguinski