text: #!/usr/bin/env python
  """
  @file    test.py
  @author  Pablo Alvarez Lopez
  @date    2016-11-25
  @version $Id$
  
  python script used by sikulix for testing netedit
  
  SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
  Copyright (C) 2009-2017 DLR/TS, Germany
  
  This file is part of SUMO.
  SUMO is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 3 of the License, or
  (at your option) any later version.
  """
  # import common functions for netedit tests
  import os
  import sys
  
  testRoot = os.path.join(os.environ.get('SUMO_HOME', '.'), 'tests')
  neteditTestRoot = os.path.join(
      os.environ.get('TEXTTEST_HOME', testRoot), 'netedit')
  sys.path.append(neteditTestRoot)
  import neteditTestFunctions as netedit  # noqa
  
  # Open netedit
  neteditProcess, match = netedit.setupAndStart(neteditTestRoot)
  
  # go to additional mode
  netedit.additionalMode()
  
  # select routeProbe
  netedit.changeAdditional("routeProbe")
  
  # create routeProbe
  netedit.leftClick(match, 380, 200)
  
  # Change to delete
  netedit.deleteMode()
  
  # delete loaded routeProbe
  netedit.leftClick(match, 310, 200)
  
  # delete created routeProbe (using stack)
  netedit.leftClick(match, 310, 200)
  
  # delete lane with the second loaded routeProbe
  netedit.leftClick(match, 280, 250)
  
  # Check undo
  netedit.undo(match, 3)
  
  # Change to delete
  netedit.deleteMode()
  
  # disable 'Automatically delete additionals'
  netedit.changeAutomaticallyDeleteAdditionals(match)
  
  # try to delete lane with the second loaded routeProbe (doesn't allowed)
  netedit.leftClick(match, 280, 250)
  
  # wait warning
  netedit.waitAutomaticallyDeleteAdditionalsWarning()
  
  # check redo
  netedit.redo(match, 3)
  
  # save additionals
  netedit.saveAdditionals()
  
  # save newtork
  netedit.saveNetwork()
  
  # quit netedit
  netedit.quit(neteditProcess)
  