#NEWLINE# def _TestTags( kind , name ) : #NEWLINE# #INDENT# 'Generic function for add-tags.\n\n  ' #NEWLINE# def cmdfn( subcmd ) : #NEWLINE# #INDENT# cmd = [ _KIND_TO_COMMAND [ kind ] , subcmd ] #NEWLINE# if ( kind != constants . TAG_CLUSTER ) : #NEWLINE# #INDENT# cmd . append ( name ) #NEWLINE# #UNINDENT# return cmd #NEWLINE# #UNINDENT# for cmd in [ ( cmdfn ( 'add-tags' ) + _TEMP_TAG_NAMES ) , cmdfn ( 'list-tags' ) , [ 'gnt-cluster' , 'search-tags' , _TEMP_TAG_RE ] , ( cmdfn ( 'remove-tags' ) + _TEMP_TAG_NAMES ) ] : #NEWLINE# #INDENT# AssertCommand ( cmdfn ) #NEWLINE# #UNINDENT# if qa_rapi . Enabled ( ) : #NEWLINE# #INDENT# qa_rapi . TestTags ( kind , name , _TEMP_TAG_NAMES )