fix:python error

This commit is contained in:
wangmm0220 2024-01-30 09:38:14 +08:00
parent c3a6806239
commit d66d5335bb
1 changed files with 3 additions and 3 deletions

View File

@ -129,10 +129,10 @@ class TDTestCase:
if not exceptOccured: if not exceptOccured:
tdLog.exit(f"has no privilege, should except") tdLog.exit(f"has no privilege, should except")
checkUserPrivileges(1) self.checkUserPrivileges(1)
tdLog.debug("test subscribe topic privilege granted by other user") tdLog.debug("test subscribe topic privilege granted by other user")
tdSql.execute(f'grant subscribe on {self.topic_name} to {self.user_name}') tdSql.execute(f'grant subscribe on {self.topic_name} to {self.user_name}')
checkUserPrivileges(2) self.checkUserPrivileges(2)
exceptOccured = False exceptOccured = False
try: try:
@ -159,7 +159,7 @@ class TDTestCase:
tdLog.debug("test subscribe topic privilege revoked by other user") tdLog.debug("test subscribe topic privilege revoked by other user")
tdSql.execute(f'revoke subscribe on {self.topic_name} from {self.user_name}') tdSql.execute(f'revoke subscribe on {self.topic_name} from {self.user_name}')
checkUserPrivileges(1) self.checkUserPrivileges(1)
time.sleep(5) time.sleep(5)
finally: finally: