def test_coercing_fill_value_type():
 t = Table({'a': ['1']}, masked=True)
 t['a'].set_fill_value('0')
 t2 = Table(t, names=['a'], dtype=[np.int32])
 assert isinstance(t2['a'].fill_value, np.int32)
 c = MaskedColumn(['1'])
 c.set_fill_value('0')
 c2 = MaskedColumn(c, dtype=np.int32)
 assert isinstance(c2.fill_value, np.int32)

def test_coercing_fill_value_type ( ) : t = Table ( { 'a' : [ '1' ] } , masked = True ) t [ 'a' ] . set_fill_value ( '0' ) t2 = Table ( t , names = [ 'a' ] , dtype = [ np . int32 ] ) assert isinstance ( t2 [ 'a' ] . fill_value , np . int32 ) c = MaskedColumn ( [ '1' ] ) c . set_fill_value ( '0' ) c2 = MaskedColumn ( c , dtype = np . int32 ) assert isinstance ( c2 . fill_value , np . int32 )
test that masked column fill_value is coerced into the correct column type .