#NEWLINE# def test_do_port_list_detail_wrong_sort_key( self ) : #NEWLINE# #INDENT# client_mock = mock . MagicMock ( ) #NEWLINE# args = self . _get_client_mock_args ( sort_key = 'node_uuid' , detail = True ) #NEWLINE# self . assertRaises ( exceptions . CommandError , p_shell . do_port_list , client_mock , args ) #NEWLINE# self . assertFalse ( client_mock . port . list . called )