From 003f9138bc145836707723ad2709076e3a5e9065 Mon Sep 17 00:00:00 2001 From: Chris Zhai Date: Wed, 29 May 2024 14:59:22 +0800 Subject: [PATCH] add test cases for TS-4721 --- tests/army/enterprise/alter/alterConfig.py | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 tests/army/enterprise/alter/alterConfig.py diff --git a/tests/army/enterprise/alter/alterConfig.py b/tests/army/enterprise/alter/alterConfig.py new file mode 100644 index 0000000000..7413e5e5a6 --- /dev/null +++ b/tests/army/enterprise/alter/alterConfig.py @@ -0,0 +1,55 @@ +################################################################### +# 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 -*- + +import sys +import time + +import taos +import frame +import frame.etool + +from frame.log import * +from frame.cases import * +from frame.sql import * +from frame.caseBase import * +from frame import * + + +class TDTestCase(TBase): + def alterSupportVnodes(self): + tdLog.info(f"test function of altering supportVnodes") + + tdSql.execute("alter dnode 1 'supportVnodes' '128'") + time.sleep(1) + tdSql.query('show dnodes') + tdSql.checkData(0, 3, "128") + + tdSql.execute("alter dnode 1 'supportVnodes' '64'") + time.sleep(1) + tdSql.query('show dnodes') + tdSql.checkData(0, 3, "64") + + # run + def run(self): + tdLog.debug(f"start to excute {__file__}") + + # TS-4721 + self.alterSupportVnodes() + + + tdLog.success(f"{__file__} successfully executed") + + + +tdCases.addLinux(__file__, TDTestCase()) +tdCases.addWindows(__file__, TDTestCase())