equal_rights_for_hash 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- 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
|