summaryrefslogtreecommitdiff
path: root/python/test/Ice/faultTolerance/Client.py
blob: 7896bc12036bdaf81bb8580fdc82644e60fe183d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/usr/bin/env python
# **********************************************************************
#
# Copyright (c) 2003-present ZeroC, Inc. All rights reserved.
#
# **********************************************************************


from TestHelper import TestHelper
import AllTests


class Client(TestHelper):

    def run(self, args):

        properties = self.createTestProperties(args)

        #
        # This test aborts servers, so we don't want warnings.
        #
        properties.setProperty('Ice.Warn.Connections', '0')

        ports = []
        for arg in args:
            if arg[0] == '-':
                continue
            ports.append(int(arg))

        if len(ports) == 0:
            raise RuntimeError("no ports specified")

        with self.initialize(properties=properties) as communicator:
            AllTests.allTests(self, communicator, ports)