示例#1
0
 def setUpClass(cls):
     try:
         cls.comm = create_comm_of_size(cls.comm_size)
     except InvalidCommSizeError:
         msg = "Must run with comm size >= {}."
         raise unittest.SkipTest(msg.format(cls.comm_size))
 def test_size_too_big(self):
     """ Test that a comm of size with too many nodes will fail. """
     too_many = 2 * self.max_size
     with self.assertRaises(InvalidCommSizeError):
         create_comm_of_size(too_many)
示例#3
0
 def setUpClass(cls):
     try:
         cls.comm = create_comm_of_size(cls.comm_size)
     except InvalidCommSizeError:
         msg = "Must run with comm size >= {}."
         raise unittest.SkipTest(msg.format(cls.comm_size))
示例#4
0
 def test_size_too_big(self):
     """ Test that a comm of size with too many nodes will fail. """
     too_many = 2 * self.max_size
     with self.assertRaises(InvalidCommSizeError):
         create_comm_of_size(too_many)