#NEWLINE# @ given ( start_action_messages , message_dicts ) #NEWLINE# def test_wrong_task_level( self , start_message , child_message ) : #NEWLINE# #INDENT# "\n        All child messages of an action must have a task level that is a direct\n        child of the action's task level.\n        " #NEWLINE# assume ( ( not start_message . task_level . is_sibling_of ( TaskLevel ( level = child_message [ TASK_LEVEL_FIELD ] ) ) ) ) #NEWLINE# message = written_from_pmap ( child_message . update ( { #NEWLINE# #INDENT# TASK_UUID_FIELD : start_message . task_uuid , #NEWLINE# #UNINDENT# } ) ) #NEWLINE# self . assertRaises ( WrongTaskLevel , WrittenAction . from_messages , start_message , v ( message ) )