OneMnodeMultipleVnodesTest.py 1.1 KB
Newer Older
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 35 36 37 38
###################################################################
#           Copyright (c) 2016 by TAOS Technologies, Inc.
#                     All rights reserved.
#
#  This file is proprietary and confidential to TAOS Technologies.
#  No part of this file may be reproduced, stored, transmitted,
#  disclosed or used in any form or by any means other than as
#  expressly provided by the written permission from Jianhui Tao
#
###################################################################

# -*- coding: utf-8 -*-

from basic import *

class TDTestCase:

    def init(self):
        # tdLog.debug("start to execute %s" % __file__)

        self.numOfNodes = 5
        self.dockerDir = "/data"
        cluster.init(self.numOfNodes, self.dockerDir)        
        cluster.prepardBuild()
        for i in range(self.numOfNodes):
            if i == 0:
                cluster.cfg("role", "1", i + 1)
            else:
                cluster.cfg("role", "2", i + 1)
        cluster.run()

td = TDTestCase()
td.init()


## usage:  python3 OneMnodeMultipleVnodesTest.py