'Testing writing to a 1D array within a structured type'

def test_record_write_array(self):

    nbval = np.recarray(1, dtype=recordwitharray)
    nbrecord = numpy_support.from_dtype(recordwitharray)
    cfunc = self.get_cfunc(record_write_array, (nbrecord,))
    cfunc(nbval[0])
    expected = np.recarray(1, dtype=recordwitharray)
    expected[0].g = 2
    expected[0].h[0] = 3.0
    expected[0].h[1] = 4.0
    np.testing.assert_equal(expected, nbval)
