summaryrefslogtreecommitdiff
path: root/test/csv/test_row.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/csv/test_row.rb')
-rwxr-xr-xtest/csv/test_row.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/csv/test_row.rb b/test/csv/test_row.rb
index 23df4d4fe60..67ed65c0dbe 100755
--- a/test/csv/test_row.rb
+++ b/test/csv/test_row.rb
@@ -419,4 +419,12 @@ class TestCSV::Row < TestCSV
row.dig("A", 0)
end
end
+
+ def test_dup
+ row = CSV::Row.new(["A"], ["foo"])
+ dupped_row = row.dup
+ dupped_row.delete("A")
+ assert_equal(["foo", nil],
+ [row["A"], dupped_row["A"]])
+ end
end