def test_create_comm_with_list(self):
     """ Test that create_comm_with_list() works correctly. """
     nodes = [0, 1, 2, 3]
     comm = create_comm_with_list(nodes)
     if comm == MPI.COMM_NULL:
         # Only proceed when not COMM_NULL.
         return
     # Run a simple test to confirm this comm works.
     size = len(nodes)
     nrows = size * 3
     a = dla.zeros((nrows, 20), comm=comm)
     expected = numpy.zeros((nrows // size, 20))
     assert_array_equal(a.local_array, expected)
     # Cleanup.
     comm.Free()
 def test_zeros(self):
     size = self.get_comm_size()
     nrows = size * 3
     a = dla.zeros((nrows, 20), comm=self.comm)
     expected = np.zeros((nrows / size, 20))
     assert_array_equal(a.local_array, expected)