Commits

Brian Kearns committed 645c4b2

fix these tests on 32bit

  • Participants
  • Parent commits bb1a119

Comments (0)

Files changed (2)

pypy/module/micronumpy/test/test_numarray.py

             assert b.shape == (1,)
             assert b[0][0] == 25185
             assert b[0][1] == 12643
-        a = array([(1, 2)], dtype=[('a', int), ('b', int)])[0]
+        a = array([(1, 2)], dtype=[('a', 'int64'), ('b', 'int64')])[0]
         assert a.shape == ()
         assert a.view('S16') == '\x01' + '\x00' * 7 + '\x02'
-        a = array(2, dtype=int)
+        a = array(2, dtype='int64')
         b = a.view('complex64')
         assert 0 < b.real < 1
         assert b.imag == 0
         x = array(['abc', 'defg'], dtype='string')
         assert x.view('S4')[0] == 'abc'
         assert x.view('S4')[1] == 'defg'
-        a = array([(1, 2)], dtype=[('a', int), ('b', int)])
+        a = array([(1, 2)], dtype=[('a', 'int64'), ('b', 'int64')])
         assert a.view('S16')[0] == '\x01' + '\x00' * 7 + '\x02'
 
     def test_ndarray_view_empty(self):

pypy/module/micronumpy/test/test_scalar.py

             assert b[0] == 25185
             assert b[1] == 12643
         if '__pypy__' in sys.builtin_module_names:
-            raises(TypeError, "np.dtype([('a', int), ('b', int)]).type('a' * 16)")
+            raises(TypeError, "np.dtype([('a', 'int64'), ('b', 'int64')]).type('a' * 16)")
         else:
-            s = np.dtype([('a', int), ('b', int)]).type('a' * 16)
+            s = np.dtype([('a', 'int64'), ('b', 'int64')]).type('a' * 16)
             assert s.view('S16') == 'a' * 16
 
     def test_complex_scalar_complex_cast(self):