progressrus 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/progressrus/version.rb +1 -1
- data/lib/progressrus.rb +2 -0
- data/test/integration_test.rb +1 -0
- data/test/progressrus_test.rb +7 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a654e74220bfd54eb96f2c18390e8fcc794ae937
|
4
|
+
data.tar.gz: db38bb7f163a7ef1d2cca42fde38a644464e0316
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 80adef7173fa11523e3ea323333d8b4dd50cfdc9b88c41dc85ba718b9c2b5f0e25a97086f9e0e552e9b1878ac4c0e07aefd20e8d9370ca7ffe0f776d7d78a5b1
|
7
|
+
data.tar.gz: 2a4bdbef69f9f31d8675f922ff73d02325c1732d8fb24823b12b6765ca1451cb6f0176af7c45e08b817663d1fa65e613951300480a88941f2818fb045863cc08
|
data/lib/progressrus/version.rb
CHANGED
data/lib/progressrus.rb
CHANGED
data/test/integration_test.rb
CHANGED
data/test/progressrus_test.rb
CHANGED
@@ -119,6 +119,13 @@ class ProgressrusTest < Minitest::Test
|
|
119
119
|
assert_equal 0, @progress.percentage
|
120
120
|
end
|
121
121
|
|
122
|
+
def test_percentage_should_be_nil_if_total_nil
|
123
|
+
progress = Progressrus.new(total: nil)
|
124
|
+
assert_nil progress.percentage
|
125
|
+
progress.tick
|
126
|
+
assert_nil progress.percentage
|
127
|
+
end
|
128
|
+
|
122
129
|
def test_percentage_should_be_1_if_total_0
|
123
130
|
progress = Progressrus.new(total: 0)
|
124
131
|
assert_equal 1, progress.percentage
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: progressrus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon Eskildsen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01-
|
11
|
+
date: 2018-01-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: redis
|