much-decimal 0.1.1 → 0.1.2

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
- ---
2
- SHA1:
3
- data.tar.gz: defcdf171b49f129b69685c1a999a1872843d112
4
- metadata.gz: 0a02551889905e311afb337fed92d4c9b53c7427
5
- SHA512:
6
- data.tar.gz: 6f6638b2f55058c237cb24a6a91d0f2fe113f0280eae6f66872489d9337d9e9f2dea559c0d09c14cf41862105b29f6191ac0c8d80ec0e0647ece5b300990d5d8
7
- metadata.gz: 8da6b0a650cce4c7f80958f99c36cf87df22491f8e68a8dd5d17b60469e79afe44e793be46bd6c789222ce994e031835985a604f6c3a203b775c8f9edec9d950
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 17deac20653a970e1af8304da862f557e10c701e2b5ac469ea468f04e9e4dfa5
4
+ data.tar.gz: 93ba2c5485af9d79cebd1fae5457b92acec08dc4669e4fec1106c63ce4d05f74
5
+ SHA512:
6
+ metadata.gz: 1e02c119bffc8890aaf82acc21ae2c65050cc06e5a221411774b13b1118060c0b9ded30fb560fc6192be201496283935c6fbd582963db28f602b996bf17ba957
7
+ data.tar.gz: d99c011bbe87a62916b9a2d445d398a75b88badd3c7e1eebaee28901e40dbfb8eaeab6505c7c11f95bfb3a7ee1702c525c50e8464bcc589bd17aa9d86f6f1598
data/.l.yml ADDED
@@ -0,0 +1,8 @@
1
+ # https://github.com/redding/l.rb
2
+
3
+ linters:
4
+ - name: "Rubocop"
5
+ cmd: "bundle exec rubocop"
6
+ extensions:
7
+ - ".rb"
8
+ cli_abbrev: "u"
@@ -0,0 +1,6 @@
1
+ inherit_gem:
2
+ much-style-guide:
3
+ - "lib/much-style-guide/rubocop.yml"
4
+
5
+ AllCops:
6
+ SuggestExtensions: false
@@ -0,0 +1 @@
1
+ 2.5.8
data/.t.yml ADDED
@@ -0,0 +1,4 @@
1
+ - default_cmd: "bundle exec assert"
2
+ test_dir: "test"
3
+ test_file_suffixes:
4
+ - "_tests.rb"
data/Gemfile CHANGED
@@ -1,5 +1,9 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source "https://rubygems.org"
2
4
 
5
+ ruby "~> 2.5"
6
+
3
7
  gemspec
4
8
 
5
- gem 'pry', "~> 0.9.0"
9
+ gem "pry"
data/README.md CHANGED
@@ -10,7 +10,7 @@ TODO: Write code samples and usage instructions here
10
10
 
11
11
  Add this line to your application's Gemfile:
12
12
 
13
- gem 'much-decimal'
13
+ gem "much-decimal"
14
14
 
15
15
  And then execute:
16
16
 
@@ -1,77 +1,69 @@
1
- require 'much-plugin'
1
+ # frozen_string_literal: true
2
2
 
3
- require 'much-decimal/version'
3
+ require "much-decimal/version"
4
+ require "much-mixin"
4
5
 
5
6
  module MuchDecimal
6
- include MuchPlugin
7
+ include MuchMixin
7
8
 
8
- DEFAULT_PRECISION = 2.freeze
9
+ DEFAULT_PRECISION = 2
9
10
 
10
11
  def self.integer_to_decimal(integer, precision)
11
12
  if integer.respond_to?(:to_i) && !integer.to_s.empty?
12
- base_10_modifier = (10.0 ** precision)
13
+ base_10_modifier = (10.0**precision)
13
14
  integer.to_i / base_10_modifier
14
15
  end
15
16
  end
16
17
 
17
18
  def self.decimal_to_integer(decimal, precision)
18
19
  if decimal.respond_to?(:to_f) && !decimal.to_s.empty?
19
- base_10_modifier = (10.0 ** precision)
20
+ base_10_modifier = (10.0**precision)
20
21
  (decimal.to_f * base_10_modifier).round.to_i
21
22
  end
22
23
  end
23
24
 
24
- plugin_included do
25
- extend ClassMethods
26
- end
27
-
28
- module ClassMethods
29
-
30
- def decimal_as_integer(attribute, options = nil)
31
- options ||= {}
32
- source = options[:source] || "#{attribute}_as_integer"
33
- precision = (options[:precision] || DEFAULT_PRECISION).to_i
34
-
35
- define_method(attribute) do
36
- integer = self.send(source)
37
- MuchDecimal.integer_to_decimal(integer, precision)
38
- end
39
-
40
- define_method("#{attribute}=") do |decimal|
41
- integer = MuchDecimal.decimal_to_integer(decimal, precision)
42
- self.send("#{source}=", integer)
43
- end
25
+ mixin_class_methods do
26
+ def decimal_as_integer(attribute, source: nil, precision: nil)
27
+ source ||= "#{attribute}_as_integer"
28
+ precision = (precision || DEFAULT_PRECISION).to_i
29
+
30
+ class_eval(<<~RUBY, __FILE__, __LINE__ + 1)
31
+ def #{attribute}
32
+ MuchDecimal.integer_to_decimal(#{source}, #{precision})
33
+ end
34
+
35
+ def #{attribute}=(decimal_value)
36
+ self.#{source} =
37
+ MuchDecimal.decimal_to_integer(decimal_value, #{precision})
38
+ end
39
+ RUBY
44
40
  end
45
-
46
41
  end
42
+ end
47
43
 
48
- module TestHelpers
49
- include MuchPlugin
50
-
51
- plugin_included do
52
- include InstanceMethods
53
-
54
- require 'assert/factory'
55
- end
56
-
57
- module InstanceMethods
58
-
59
- def assert_decimal_as_integer(subject, attribute, options = nil)
60
- options ||= {}
61
- source = options[:source] || "#{attribute}_as_integer"
62
- precision = (options[:precision] || DEFAULT_PRECISION).to_i
63
-
64
- value = Assert::Factory.float
65
- subject.send("#{attribute}=", value)
44
+ module MuchDecimal::TestHelpers
45
+ include MuchMixin
66
46
 
67
- exp = MuchDecimal.decimal_to_integer(value, precision)
68
- assert_equal exp, subject.send(source)
69
- exp = MuchDecimal.integer_to_decimal(exp, precision)
70
- assert_equal exp, subject.send(attribute)
71
- end
47
+ mixin_included do
48
+ require "assert/factory"
49
+ end
72
50
 
51
+ mixin_instance_methods do
52
+ def assert_decimal_as_integer(
53
+ subject,
54
+ attribute,
55
+ source: nil,
56
+ precision: nil)
57
+ source ||= "#{attribute}_as_integer"
58
+ precision = (precision || MuchDecimal::DEFAULT_PRECISION).to_i
59
+
60
+ value = Assert::Factory.float
61
+ subject.public_send("#{attribute}=", value)
62
+
63
+ integer = MuchDecimal.decimal_to_integer(value, precision)
64
+ assert_that(subject.public_send(source)).equals(integer)
65
+ assert_that(subject.public_send(attribute))
66
+ .equals(MuchDecimal.integer_to_decimal(integer, precision))
73
67
  end
74
-
75
68
  end
76
-
77
69
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module MuchDecimal
2
- VERSION = "0.1.1"
4
+ VERSION = "0.1.2"
3
5
  end
File without changes
@@ -1,5 +1,7 @@
1
1
  # -*- encoding: utf-8 -*-
2
- lib = File.expand_path('../lib', __FILE__)
2
+ # frozen_string_literal: true
3
+
4
+ lib = File.expand_path("../lib", __FILE__)
3
5
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
6
  require "much-decimal/version"
5
7
 
@@ -11,15 +13,17 @@ Gem::Specification.new do |gem|
11
13
  gem.summary = "Define decimal attributes that are stored as integers"
12
14
  gem.description = "Define decimal attributes that are stored as integers"
13
15
  gem.homepage = "https://github.com/redding/much-decimal"
14
- gem.license = 'MIT'
16
+ gem.license = "MIT"
15
17
 
16
- gem.files = `git ls-files`.split($/)
18
+ gem.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR)
17
19
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
18
20
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
19
21
  gem.require_paths = ["lib"]
20
22
 
21
- gem.add_development_dependency("assert", ["~> 2.16.1"])
23
+ gem.required_ruby_version = "~> 2.5"
22
24
 
23
- gem.add_dependency('much-plugin', ["~> 0.2.0"])
25
+ gem.add_development_dependency("assert", ["~> 2.19.2"])
26
+ gem.add_development_dependency("much-style-guide", ["~> 0.4.0"])
24
27
 
28
+ gem.add_dependency("much-mixin", ["~> 0.2.3"])
25
29
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # this file is automatically required when you run `assert`
2
4
  # put any test helpers here
3
5
 
@@ -5,15 +7,6 @@
5
7
  $LOAD_PATH.unshift(File.expand_path("../..", __FILE__))
6
8
 
7
9
  # require pry for debugging (`binding.pry`)
8
- require 'pry'
9
-
10
- require 'test/support/factory'
11
-
12
- # 1.8.7 backfills
10
+ require "pry"
13
11
 
14
- # Array#sample
15
- if !(a = Array.new).respond_to?(:sample) && a.respond_to?(:choice)
16
- class Array
17
- alias_method :sample, :choice
18
- end
19
- end
12
+ require "test/support/factory"
@@ -1,6 +1,7 @@
1
- require 'assert/factory'
1
+ # frozen_string_literal: true
2
+
3
+ require "assert/factory"
2
4
 
3
5
  module Factory
4
6
  extend Assert::Factory
5
-
6
7
  end
@@ -1,220 +1,214 @@
1
- require 'assert'
2
- require 'much-decimal'
1
+ # frozen_string_literal: true
3
2
 
4
- module MuchDecimal
3
+ require "assert"
4
+ require "much-decimal"
5
5
 
6
+ module MuchDecimal
6
7
  class UnitTests < Assert::Context
7
8
  desc "MuchDecimal"
8
- setup do
9
- @module = MuchDecimal
10
- end
11
- subject{ @module }
9
+ subject{ unit_module }
10
+
11
+ let(:unit_module){ MuchDecimal }
12
+
13
+ let(:integer){ Factory.integer }
14
+ let(:decimal){ Factory.float }
15
+ let(:precision){ Factory.integer(10) }
16
+ let(:base_10_modifier){ 10.0**precision }
17
+ let(:invalid_value){ [nil, "", true, false].sample }
12
18
 
13
19
  should have_imeths :integer_to_decimal, :decimal_to_integer
14
20
 
15
- should "use much-plugin" do
16
- assert_includes MuchPlugin, subject
21
+ should "use MuchMixin" do
22
+ assert_that(subject).includes(MuchMixin)
17
23
  end
18
24
 
19
25
  should "know its default precision" do
20
- assert_equal 2, DEFAULT_PRECISION
26
+ assert_that(DEFAULT_PRECISION).equals(2)
21
27
  end
22
28
 
23
29
  should "know how to convert an integer to a decimal" do
24
- integer = Factory.integer
25
- precision = Factory.integer(10)
26
- base_10_modifier = (10.0 ** precision)
27
-
28
30
  exp = integer / base_10_modifier
29
- assert_equal exp, subject.integer_to_decimal(integer, precision)
30
- assert_equal exp, subject.integer_to_decimal(integer.to_s, precision)
31
+ assert_that(subject.integer_to_decimal(integer, precision)).equals(exp)
32
+ assert_that(subject.integer_to_decimal(integer.to_s, precision))
33
+ .equals(exp)
31
34
 
32
- invalid_value = [nil, '', true, false].sample
33
- assert_nil subject.integer_to_decimal(invalid_value, precision)
35
+ assert_that(subject.integer_to_decimal(invalid_value, precision)).is_nil
34
36
  end
35
37
 
36
38
  should "know how to convert a decimal to an integer" do
37
- decimal = Factory.float
38
- precision = Factory.integer(10)
39
- base_10_modifier = (10.0 ** precision)
40
-
41
39
  exp = (decimal * base_10_modifier).round.to_i
42
- assert_equal exp, subject.decimal_to_integer(decimal, precision)
43
- assert_equal exp, subject.decimal_to_integer(decimal.to_s, precision)
40
+ assert_that(subject.decimal_to_integer(decimal, precision)).equals(exp)
41
+ assert_that(subject.decimal_to_integer(decimal.to_s, precision))
42
+ .equals(exp)
44
43
 
45
- invalid_value = [nil, '', true, false].sample
46
- assert_nil subject.decimal_to_integer(invalid_value, precision)
44
+ assert_that(subject.decimal_to_integer(invalid_value, precision)).is_nil
47
45
  end
48
-
49
46
  end
50
47
 
51
- class MixinSetupTests < UnitTests
52
- setup do
53
- @class = Class.new do
48
+ class ReceiverSetupTests < UnitTests
49
+ subject{ receiver_class }
50
+
51
+ let(:receiver_class) do
52
+ Class.new do
54
53
  include MuchDecimal
55
54
  attr_accessor :seconds_as_integer, :integer_seconds
56
55
  end
57
56
  end
58
- subject{ @class }
59
-
60
57
  end
61
58
 
62
- class MixinTests < MixinSetupTests
63
- desc "when mixed in"
59
+ class ReceiverTests < ReceiverSetupTests
60
+ desc "receiver"
61
+
62
+ let(:decimal){ Factory.float }
63
+ let(:integer){ Factory.integer }
64
+
65
+ let(:custom_source){ :integer_seconds }
66
+ let(:custom_precision){ Factory.integer(5) }
64
67
 
65
68
  should have_imeths :decimal_as_integer
66
69
 
67
70
  should "add a decimal-as-integer accessor using `decimal_as_integer`" do
68
- subject.decimal_as_integer :seconds
69
-
70
- instance = subject.new
71
- assert_respond_to :seconds, instance
72
- assert_respond_to :seconds=, instance
71
+ subject.decimal_as_integer(:seconds)
73
72
 
74
- decimal = Factory.float
75
- integer = Factory.integer
73
+ receiver = subject.new
74
+ assert_that(receiver).responds_to(:seconds)
75
+ assert_that(receiver).responds_to(:seconds=)
76
76
 
77
- instance.seconds = decimal
78
- exp = @module.decimal_to_integer(decimal, DEFAULT_PRECISION)
79
- assert_equal exp, instance.seconds_as_integer
77
+ receiver.seconds = decimal
78
+ assert_that(receiver.seconds_as_integer)
79
+ .equals(unit_module.decimal_to_integer(decimal, DEFAULT_PRECISION))
80
80
 
81
- instance.seconds_as_integer = integer
82
- exp = @module.integer_to_decimal(integer, DEFAULT_PRECISION)
83
- assert_equal exp, instance.seconds
81
+ receiver.seconds_as_integer = integer
82
+ assert_that(receiver.seconds)
83
+ .equals(unit_module.integer_to_decimal(integer, DEFAULT_PRECISION))
84
84
  end
85
85
 
86
86
  should "allow specifying custom options using `decimal_as_integer`" do
87
- source = :integer_seconds
88
- precision = Factory.integer(5)
89
- subject.decimal_as_integer :seconds, {
90
- :source => source,
91
- :precision => precision
92
- }
93
-
94
- instance = subject.new
95
- assert_respond_to :seconds, instance
96
- assert_respond_to :seconds=, instance
87
+ subject.decimal_as_integer(
88
+ :seconds,
89
+ source: custom_source,
90
+ precision: custom_precision,
91
+ )
97
92
 
98
- decimal = Factory.float
99
- integer = Factory.integer
93
+ receiver = subject.new
94
+ assert_that(receiver).responds_to(:seconds)
95
+ assert_that(receiver).responds_to(:seconds=)
100
96
 
101
- instance.seconds = decimal
102
- exp = @module.decimal_to_integer(decimal, precision)
103
- assert_equal exp, instance.send(source)
97
+ receiver.seconds = decimal
98
+ assert_that(receiver.public_send(custom_source))
99
+ .equals(unit_module.decimal_to_integer(decimal, custom_precision))
104
100
 
105
- instance.send("#{source}=", integer)
106
- exp = @module.integer_to_decimal(integer, precision)
107
- assert_equal exp, instance.seconds
101
+ receiver.public_send("#{custom_source}=", integer)
102
+ assert_that(receiver.seconds)
103
+ .equals(unit_module.integer_to_decimal(integer, custom_precision))
108
104
  end
109
-
110
105
  end
111
106
 
112
107
  class EdgeCaseTests < UnitTests
113
108
  desc "edge cases"
114
- setup do
115
- @class = Class.new do
109
+ subject{ receiver_class.new }
110
+
111
+ let(:receiver_class) do
112
+ Class.new do
116
113
  include MuchDecimal
117
114
 
118
115
  attr_accessor :ten_thousandth_seconds
119
116
 
120
- decimal_as_integer(:seconds, {
121
- :source => :ten_thousandth_seconds,
122
- :precision => 4
123
- })
117
+ decimal_as_integer :seconds,
118
+ source: :ten_thousandth_seconds,
119
+ precision: 4
124
120
  end
125
- @instance = @class.new
126
121
  end
127
- subject{ @instance }
128
122
 
129
123
  should "allow writing and reading `nil` values" do
130
- assert_nil subject.ten_thousandth_seconds
131
- assert_nil subject.seconds
124
+ assert_that(subject.ten_thousandth_seconds).is_nil
125
+ assert_that(subject.seconds).is_nil
132
126
 
133
127
  subject.seconds = 1.2345
134
- assert_equal 12345, subject.ten_thousandth_seconds
135
- assert_equal 1.2345, subject.seconds
128
+ assert_that(subject.ten_thousandth_seconds).equals(12345)
129
+ assert_that(subject.seconds).equals(1.2345)
136
130
 
137
- assert_nothing_raised{ subject.seconds = nil }
138
- assert_nil subject.seconds
139
- assert_nil subject.ten_thousandth_seconds
131
+ assert_that{ subject.seconds = nil }.does_not_raise
132
+ assert_that(subject.seconds).is_nil
133
+ assert_that(subject.ten_thousandth_seconds).is_nil
140
134
  end
141
135
 
142
136
  should "write empty string values as `nil` values" do
143
137
  subject.seconds = 1.2345
144
- assert_not_nil subject.ten_thousandth_seconds
145
- assert_not_nil subject.seconds
138
+ assert_that(subject.ten_thousandth_seconds).is_not_nil
139
+ assert_that(subject.seconds).is_not_nil
146
140
 
147
- assert_nothing_raised{ subject.seconds = '' }
148
- assert_nil subject.seconds
149
- assert_nil subject.ten_thousandth_seconds
141
+ assert_that{ subject.seconds = "" }.does_not_raise
142
+ assert_that(subject.seconds).is_nil
143
+ assert_that(subject.ten_thousandth_seconds).is_nil
150
144
  end
151
145
 
152
146
  should "write values that can't be converted as `nil` values" do
153
147
  subject.seconds = 1.2345
154
- assert_not_nil subject.ten_thousandth_seconds
155
- assert_not_nil subject.seconds
148
+ assert_that(subject.ten_thousandth_seconds).is_not_nil
149
+ assert_that(subject.seconds).is_not_nil
156
150
 
157
- assert_nothing_raised{ subject.seconds = true }
158
- assert_nil subject.seconds
159
- assert_nil subject.ten_thousandth_seconds
151
+ assert_that{ subject.seconds = true }.does_not_raise
152
+ assert_that(subject.seconds).is_nil
153
+ assert_that(subject.ten_thousandth_seconds).is_nil
160
154
  end
161
155
 
162
156
  should "handle decimals with less significant digits" do
163
157
  subject.seconds = 1.12
164
- assert_equal 11200, subject.ten_thousandth_seconds
165
- assert_equal 1.12, subject.seconds
158
+ assert_that(subject.ten_thousandth_seconds).equals(11200)
159
+ assert_that(subject.seconds).equals(1.12)
166
160
  end
167
161
 
168
162
  should "handle integers" do
169
163
  subject.seconds = 5
170
- assert_equal 50000, subject.ten_thousandth_seconds
171
- assert_equal 5.0, subject.seconds
164
+ assert_that(subject.ten_thousandth_seconds).equals(50000)
165
+ assert_that(subject.seconds).equals(5.0)
172
166
  end
173
167
 
174
168
  should "handle decimals that are less than 1" do
175
169
  subject.seconds = 0.0001
176
- assert_equal 1, subject.ten_thousandth_seconds
177
- assert_equal 0.0001, subject.seconds
170
+ assert_that(subject.ten_thousandth_seconds).equals(1)
171
+ assert_that(subject.seconds).equals(0.0001)
178
172
  end
179
173
 
180
174
  should "handle decimals with too many significant digits by rounding" do
181
175
  subject.seconds = 1.00005
182
- assert_equal 10001, subject.ten_thousandth_seconds
183
- assert_equal 1.0001, subject.seconds
176
+ assert_that(subject.ten_thousandth_seconds).equals(10001)
177
+ assert_that(subject.seconds).equals(1.0001)
184
178
  end
185
179
 
186
180
  should "handle repeating decimals" do
187
181
  subject.seconds = 1 / 3.0
188
- assert_equal 3333, subject.ten_thousandth_seconds
189
- assert_equal 0.3333, subject.seconds
182
+ assert_that(subject.ten_thousandth_seconds).equals(3333)
183
+ assert_that(subject.seconds).equals(0.3333)
190
184
  end
191
-
192
185
  end
193
186
 
194
- class TestHelpersTests < MixinSetupTests
187
+ class TestHelpersTests < ReceiverSetupTests
195
188
  include MuchDecimal::TestHelpers
196
189
 
197
190
  desc "TestHelpers"
198
- setup do
199
- @class.decimal_as_integer :seconds
200
- @custom_precision = Factory.integer(10)
201
- @class.decimal_as_integer :other_seconds, {
202
- :source => :integer_seconds,
203
- :precision => @custom_precision
204
- }
191
+ subject{ receiver_class.new }
205
192
 
206
- @instance = @class.new
193
+ setup do
194
+ receiver_class.decimal_as_integer(:seconds)
195
+ receiver_class.decimal_as_integer(
196
+ :other_seconds,
197
+ source: :integer_seconds,
198
+ precision: @custom_precision,
199
+ )
207
200
  end
208
- subject{ @instance }
209
201
 
210
- should "provide helpers for testing that a class has json fields" do
211
- assert_decimal_as_integer subject, :seconds
212
- assert_decimal_as_integer subject, :other_seconds, {
213
- :source => :integer_seconds,
214
- :precision => @custom_precision
215
- }
216
- end
202
+ let(:custom_precision){ Factory.integer(10) }
217
203
 
204
+ should "provide helpers for testing that a class has decimal fields" do
205
+ assert_decimal_as_integer(subject, :seconds)
206
+ assert_decimal_as_integer(
207
+ subject,
208
+ :other_seconds,
209
+ source: :integer_seconds,
210
+ precision: @custom_precision,
211
+ )
212
+ end
218
213
  end
219
-
220
214
  end
metadata CHANGED
@@ -1,87 +1,106 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: much-decimal
3
- version: !ruby/object:Gem::Version
4
- version: 0.1.1
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.2
5
5
  platform: ruby
6
- authors:
6
+ authors:
7
7
  - Kelly Redding
8
8
  - Collin Redding
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
-
13
- date: 2016-06-15 00:00:00 Z
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
12
+ date: 2021-01-08 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
16
15
  name: assert
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: 2.19.2
21
+ type: :development
17
22
  prerelease: false
18
- requirement: &id001 !ruby/object:Gem::Requirement
19
- requirements:
20
- - - ~>
21
- - !ruby/object:Gem::Version
22
- version: 2.16.1
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: 2.19.2
28
+ - !ruby/object:Gem::Dependency
29
+ name: much-style-guide
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
34
+ version: 0.4.0
23
35
  type: :development
24
- version_requirements: *id001
25
- - !ruby/object:Gem::Dependency
26
- name: much-plugin
27
36
  prerelease: false
28
- requirement: &id002 !ruby/object:Gem::Requirement
29
- requirements:
30
- - - ~>
31
- - !ruby/object:Gem::Version
32
- version: 0.2.0
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: 0.4.0
42
+ - !ruby/object:Gem::Dependency
43
+ name: much-mixin
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
48
+ version: 0.2.3
33
49
  type: :runtime
34
- version_requirements: *id002
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: 0.2.3
35
56
  description: Define decimal attributes that are stored as integers
36
- email:
57
+ email:
37
58
  - kelly@kellyredding.com
38
59
  - collin.redding@me.com
39
60
  executables: []
40
-
41
61
  extensions: []
42
-
43
62
  extra_rdoc_files: []
44
-
45
- files:
46
- - .gitignore
63
+ files:
64
+ - ".gitignore"
65
+ - ".l.yml"
66
+ - ".rubocop.yml"
67
+ - ".ruby-version"
68
+ - ".t.yml"
47
69
  - Gemfile
48
70
  - LICENSE
49
71
  - README.md
50
72
  - lib/much-decimal.rb
51
73
  - lib/much-decimal/version.rb
52
- - log/.gitkeep
74
+ - log/.keep
53
75
  - much-decimal.gemspec
54
76
  - test/helper.rb
55
77
  - test/support/factory.rb
56
78
  - test/unit/much_decimal_tests.rb
57
- - tmp/.gitkeep
58
79
  homepage: https://github.com/redding/much-decimal
59
- licenses:
80
+ licenses:
60
81
  - MIT
61
82
  metadata: {}
62
-
63
83
  post_install_message:
64
84
  rdoc_options: []
65
-
66
- require_paths:
85
+ require_paths:
67
86
  - lib
68
- required_ruby_version: !ruby/object:Gem::Requirement
69
- requirements:
70
- - &id003
71
- - ">="
72
- - !ruby/object:Gem::Version
73
- version: "0"
74
- required_rubygems_version: !ruby/object:Gem::Requirement
75
- requirements:
76
- - *id003
87
+ required_ruby_version: !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - "~>"
90
+ - !ruby/object:Gem::Version
91
+ version: '2.5'
92
+ required_rubygems_version: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
77
97
  requirements: []
78
-
79
98
  rubyforge_project:
80
- rubygems_version: 2.5.1
99
+ rubygems_version: 2.7.6.2
81
100
  signing_key:
82
101
  specification_version: 4
83
102
  summary: Define decimal attributes that are stored as integers
84
- test_files:
103
+ test_files:
85
104
  - test/helper.rb
86
105
  - test/support/factory.rb
87
106
  - test/unit/much_decimal_tests.rb