equal_rights_for_hash 0.0.3 → 0.0.4
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.
- data/equal_rights_for_hash.gemspec +1 -1
- data/lib/equal_rights_for_hash.rb +2 -0
- data/test/kernel_hash_test.rb +5 -0
- metadata +1 -1
data/test/kernel_hash_test.rb
CHANGED
@@ -26,4 +26,9 @@ class TestKernelHash < Test::Unit::TestCase
|
|
26
26
|
def test_converts_empty_array_into_hash
|
27
27
|
assert_equal({}, Hash([]))
|
28
28
|
end
|
29
|
+
|
30
|
+
def test_raises_ArgumentError_on_failure
|
31
|
+
error = assert_raise(ArgumentError) { Hash("bogus") }
|
32
|
+
assert_equal('invalid value for Hash(): "bogus"', error.message)
|
33
|
+
end
|
29
34
|
end
|