Skip to content
This repository has been archived by the owner on Jan 13, 2022. It is now read-only.

Commit

Permalink
Add test for bug #41
Browse files Browse the repository at this point in the history
  • Loading branch information
kutsurak committed Jun 3, 2019
1 parent 0236a9b commit 6b6e760
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/test_pylite00.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,13 @@ def test_null_string_insertion_bug(self, initialize_monetdblite):
expected = numpy.ma.masked_array(['a', 'a'], mask=[0, 1])
numpy.testing.assert_array_equal(result['s'], expected)

def test_decimal_insertion_bug(self, initialize_monetdblite):
monetdblite.sql("CREATE TABLE pylite13 (d DECIMAL(3, 2))")
monetdblite.insert('pylite13', {'d': [1.3]})
result = monetdblite.sql("SELECT * FROM pylite13")
expected = numpy.array([1.3])
numpy.testing.assert_array_equal(result['d'], expected)

# This test must be executed after all others because it
# initializes monetdblite independently out of the fixture
# initialize_monetdblite
Expand Down

0 comments on commit 6b6e760

Please sign in to comment.