Esempio n. 1
0
# move E1 to right
netedit.moveElement(match, 120, 250, 250, 250)

# move back
netedit.moveElement(match, 250, 250, 120, 250)

# move E1 to left overpassing lane
netedit.moveElement(match, 120, 250, -150, 250)

# move back
netedit.moveElement(match, -100, 250, 120, 250)

# move E1 to right overpassing lane
netedit.moveElement(match, 120, 250, 580, 250)

# move back to another different position of initial
netedit.moveElement(match, 520, 250, 300, 250)

# Check undos and redos
netedit.undo(match, 10)
netedit.redo(match, 10)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 2
0
# go to poly mode and select poly
netedit.changeShape("poly")

# create polygon
netedit.createSquaredPoly(match, 100, 50, 100, True)

# go to delete mode
netedit.deleteMode()

# delete created polygon
netedit.leftClick(match, 100, 50)

# try to delete second polygon (not possible due isn't fill)
netedit.leftClick(match, 175, 25)

# delete loaded filled polygon
netedit.leftClick(match, 275, 25)

# Check undos and redos
netedit.undo(match, 3)
netedit.redo(match, 3)

# save shapes
netedit.saveShapes()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 3
0
# Change to inspect mode
netedit.inspectMode()

# inspect E1
netedit.leftClick(match, 350, 250)

# obtain parameters reference
parametersReference = netedit.getParametersReference(match)

# unblock additional
netedit.changeBlockAdditional(comboboxAdditional, 6)

# change to move mode
netedit.moveMode()

# move E1 to right (must be allowed)
netedit.moveElement(match, 250, 250, 350, 250)

# Check undos and redos
netedit.undo(match, 5)
netedit.redo(match, 5)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 4
0
# Change parameter 8 with a valid value
netedit.modifyAttribute(
    8,
    "-13.00,8.00 -8.00,13.00 -13.00,18.00 -18.00,23.00 -23.00,18.00 -28.00,13.00 -23.00,8.00 -18.00,3.00 -13.00,8.00"
)

# Change boolean parameter 9
netedit.modifyShapeDefaultBoolValue(9)

# Change boolean parameter 10
netedit.modifyShapeDefaultBoolValue(11)

# Change boolean parameter 11
netedit.modifyShapeDefaultBoolValue(12)

# Change boolean parameter 12
netedit.modifyShapeDefaultBoolValue(13)

# Check undos and redos
netedit.undo(match, 24)
netedit.redo(match, 24)

# save shapes
netedit.saveShapes()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 5
0
# Change parameter 19 with a duplicated value (See #3157)
netedit.modifyAttribute(19, "14,15.5")

# Change parameter 19 with a valid value (empty)
netedit.modifyAttribute(19, "")

# Change parameter 19 with a valid value
netedit.modifyAttribute(19, "34,15.5")

# recompute
netedit.rebuildNetwork()

# Check undos
netedit.undo(match, 17)

# recompute
netedit.rebuildNetwork()

# check redos
netedit.redo(match, 17)

# save additionals
netedit.saveAdditionals()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 6
0
# Change to inspect mode
netedit.inspectMode()

# inspect busStop
netedit.leftClick(match, 300, 250)

# obtain parameters reference
parametersReference = netedit.getParametersReference(match)

# unblock additional
netedit.changeBlockAdditional(comboboxAdditional, 5)

# change to move mode
netedit.moveMode()

# move busStop to right (must be allowed)
netedit.moveElement(match, 250, 275, 350, 275)

# Check undos and redos
netedit.undo(match, 5)
netedit.redo(match, 5)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess, False, False)
Esempio n. 7
0
netedit.modifyAdditionalDefaultValue(4, "2.51")

# create E3 with different speedTreshold
netedit.leftClick(match, 500, 100)

# select entry detector
netedit.changeAdditional("detEntry")

# Create Entry detectors for all E3 detectors except for the first
netedit.selectAdditionalChild(6, 1)
netedit.leftClick(match, 50, 200)
netedit.selectAdditionalChild(6, 1)
netedit.leftClick(match, 200, 250)
netedit.selectAdditionalChild(6, 1)
netedit.leftClick(match, 350, 200)
netedit.selectAdditionalChild(6, 1)
netedit.leftClick(match, 500, 250)

# Check undo redo
netedit.undo(match, 9)
netedit.redo(match, 9)

# save additionals
netedit.saveAdditionals()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 8
0
# Change parameter 5 with a non valid value (negative)
netedit.modifyAttribute(parametersReference, 5, "-5")

# Change parameter 5 with a valid value
netedit.modifyAttribute(parametersReference, 5, "4")

# Change parameter 6 with a non valid value (dummy)
netedit.modifyAttribute(parametersReference, 6, "dummySpeedTreshold")

# Change parameter 6 with a non valid value (negative)
netedit.modifyAttribute(parametersReference, 6, "-12.1")

# Change parameter 6 with a valid value
netedit.modifyAttribute(parametersReference, 6, "6.3")

# go to a empty area
netedit.leftClick(match, 0, 0);

# Check undos and redos
netedit.undo(match, 21)
netedit.redo(match, 21)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 9
0
# Change parameter 5 with a valid value
netedit.modifyAttribute(parametersReference, 5, "0.90")

# Change parameter 6 (bool)
netedit.modifyBoolAttribute(parametersReference, 6)

# Change parameter 7 with a non valid value 1
netedit.modifyAttribute(parametersReference, 7, "dummyChargeDelay")

# Change parameter 7 with a non valid value 2
netedit.modifyAttribute(parametersReference, 7, "-10")

# Change parameter 7 with a valid value
netedit.modifyAttribute(parametersReference, 7, "3")

# go to a empty area
click(match)

# Check undos and redos
netedit.undo(match, 17)
netedit.redo(match, 17)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess, False, False)
Esempio n. 10
0
# Change time threshold
netedit.modifyAttribute(comboboxAdditional, 5, "10")

# create E2 with different time threshold
netedit.leftClick(match, 150, 220)

# Change speed threshold
netedit.modifyAttribute(comboboxAdditional, 6, "2.5")

# create E2 with different speed threshold
netedit.leftClick(match, 250, 220)

# Change jam threshold
netedit.modifyAttribute(comboboxAdditional, 7, "15.5")

# create E2 with different jam threshold
netedit.leftClick(match, 350, 220)

# Check undo redo
netedit.undo(match, 7)
netedit.redo(match, 7)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 11
0
# Change parameter 3 with a valid value
netedit.modifyAttribute(parametersReference, 3, "120")

# Change parameter 4 with an empty value
netedit.modifyAttribute(parametersReference, 4, "")

# Change parameter 4 with a duplicated value
netedit.modifyAttribute(parametersReference, 4, "e1Detector_gneE2_1_1.txt")

# Change parameter 4 with a valid value
netedit.modifyAttribute(parametersReference, 4, "myOwnOutput.txt")

# Change boolean parameter 5
netedit.modifyBoolAttribute(parametersReference, 5)

# go to a empty area
click(match);

# Check undos and redos
netedit.undo(match, 12)
netedit.redo(match, 12)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 12
0
# Answer "yes" to the answer dialog
netedit.waitQuestion("y")

# Change parameter 3 with a non valid value (<startPos)
netedit.modifyAttribute(parametersReference, 3, "10")

# Change parameter 3 with a valid value
netedit.modifyAttribute(parametersReference, 3, "30")

# Change parameter 4 with a non valid value (throw warning)
netedit.modifyAttribute(parametersReference, 4, "line1, line2")

# Change parameter 4 with a valid value
netedit.modifyAttribute(parametersReference, 4, "line1 line2")

# go to a empty area
click(match);

# Check undos and redos
netedit.undo(match, 13)
netedit.redo(match, 13)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 13
0
netedit.selectChild(comboboxAdditional, 4, 3)
netedit.leftClick(match, 150, 250)

# Change to delete
netedit.deleteMode()

# delete created E3 1
netedit.leftClick(match, 100, 100)

# delete created E3 2
netedit.leftClick(match, 300, 100)

# delete loaded E3 1
netedit.leftClick(match, 400, 100)

# delete loaded E3 2
netedit.leftClick(match, 500, 100)

# Check undo redo
netedit.undo(match, 4)
netedit.redo(match, 4)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 14
0
# select E1
netedit.changeAdditional(comboboxAdditional, 6)

# create E1 with default parameters
netedit.leftClick(match, 200, 250)

# Change frequency
netedit.modifyAttribute(comboboxAdditional, 2, "150")

# create E1 with different frequency
netedit.leftClick(match, 250, 250)

# Change frequency
netedit.modifyBoolAttribute(comboboxAdditional, 3)

# create E1 with different split by type
netedit.leftClick(match, 300, 250)

# Check undo redo
netedit.undo(match, 3)
netedit.redo(match, 3)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 15
0
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

# Open netedit
neteditProcess, match = netedit.setupAndStart(neteditTestRoot, True)

# Focus netedit window
netedit.leftClick(match, 0, -105)

# Change to create mode
type("e")

# Create two nodes
netedit.leftClick(match, 100, 300)
netedit.leftClick(match, 500, 300)

# Check undo and redo
netedit.undo(match, 1)
netedit.redo(match, 1)

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess, False, False)
Esempio n. 16
0
# Change to inspect mode
netedit.inspectMode()

# inspect E3
netedit.leftClick(match, 250, 100)

# obtain parameters reference
parametersReference = netedit.getParametersReference(match)

# unblock additional
netedit.changeBlockAdditional(comboboxAdditional, 7)

# change to move mode
netedit.moveMode()

# move E3 to right (must be allowed)
netedit.moveElement(match, 120, 50, 300, 50)

# Check undos and redos
netedit.undo(match, 6)
netedit.redo(match, 6)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 17
0
# disable friendlyPos
netedit.modifyAdditionalDefaultBoolValue(3)

# change reference to "reference left"
netedit.modifyAdditionalDefaultValue(10, "reference left")

# create a busStop in mode "reference left" without friendlyPos
netedit.leftClick(match, 120, 215)

# change reference to "reference right"
netedit.modifyAdditionalDefaultValue(10, "reference right")

# create a busStop in mode "reference right" without friendlyPos
netedit.leftClick(match, 500, 215)

# Check undo redo
netedit.undo(match, 7)
netedit.redo(match, 7)

# save additionals
netedit.saveAdditionals()

# Fix stopping places position
netedit.fixStoppingPlace("fixPositions")

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 18
0
# Change speedTreshold
netedit.modifyAttribute(comboboxAdditional, 4, "2.51")

# create E3 with different speedTreshold
netedit.leftClick(match, 500, 100)

# select entry detector
netedit.changeAdditional(comboboxAdditional, -4)

# Create Entry detectors for all E3 detectors except for the first
netedit.selectChild(comboboxAdditional, 4, 1)
netedit.leftClick(match, 50, 250)
netedit.selectChild(comboboxAdditional, 4, 1)
netedit.leftClick(match, 200, 250)
netedit.selectChild(comboboxAdditional, 4, 1)
netedit.leftClick(match, 350, 250)
netedit.selectChild(comboboxAdditional, 4, 1)
netedit.leftClick(match, 500, 250)

# Check undo redo
netedit.undo(match, 9)
netedit.redo(match, 9)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 19
0
# Change parameter 9 with a valid value
netedit.modifyAttribute(9, "30")

# Change parameter 9 with a non valid value (dummy)
netedit.modifyAttribute(11, "dummyGEO")

# Change parameter 9 with a non valid value (empty)
netedit.modifyAttribute(11, "")

# Change parameter 9 with a valid value
netedit.modifyAttribute(11, "3.73,74.30")

# Change boolean parameter GEO
netedit.modifyShapeDefaultBoolValue(12)

# Change boolean parameter block
netedit.modifyShapeDefaultBoolValue(14)

# Check undos and redos
netedit.undo(match, 27)
netedit.redo(match, 27)

# save shapes
netedit.saveShapes()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 20
0
# Change parameter 4 with a non valid value (negative)
netedit.modifyAttribute(4, "-5")

# Change parameter 4 with a valid value
netedit.modifyAttribute(4, "4")

# Change parameter 5 with a non valid value (dummy)
netedit.modifyAttribute(5, "dummySpeedTreshold")

# Change parameter 5 with a non valid value (negative)
netedit.modifyAttribute(5, "-12.1")

# Change parameter 5 with a valid value
netedit.modifyAttribute(5, "6.3")

# go to a empty area
netedit.leftClick(match, 0, 0)

# Check undos and redos
netedit.undo(match, 16)
netedit.redo(match, 16)

# save additionals
netedit.saveAdditionals()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 21
0
# Change parameter 4 with an empty value
netedit.modifyAttribute(4, "")

# Change parameter 4 with an non valid value
netedit.modifyAttribute(4, "%%%&&%$%$")

# Change parameter 4 with a duplicated value
netedit.modifyAttribute(4, "e1Detector_gneE2_1_1.txt")

# Change parameter 4 with a valid value
netedit.modifyAttribute(4, "myOwnOutput.txt")

# Change parameter 5
netedit.modifyAdditionalDefaultValue(5, "private passenger taxi bus")

# Change boolean parameter 5
netedit.modifyBoolAttribute(6)

# Check undos and redos
netedit.undo(match, 12)
netedit.redo(match, 12)

# save additionals
netedit.saveAdditionals()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 22
0
# move containerStop to right
netedit.moveElement(match, 150, 275, 250, 275)

# move back
netedit.moveElement(match, 250, 275, 150, 275)

# move containerStop to left overpassing lane
netedit.moveElement(match, 150, 275, -100, 275)

# move back
netedit.moveElement(match, 0, 275, 150, 275)

# move containerStop to right overpassing lane
netedit.moveElement(match, 150, 275, 550, 275)

# move back to another different position of initial
netedit.moveElement(match, 500, 275, 300, 275)

# Check undos and redos
netedit.undo(match, 10)
netedit.redo(match, 10)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 23
0
# invert selection
netedit.selectionInvert()

# use a rectangle to check keep mode
netedit.selectionRectangle(match, 250, 150, 400, 300)

# Select "replace" mode
netedit.modificationModeReplace()

# clear selection
netedit.selectionInvert()

# use a rectangle to check replace mode
netedit.selectionRectangle(match, 250, 150, 400, 300)

# check undo and redo
netedit.undo(match, 8)
netedit.redo(match, 8)

# save additionals
netedit.saveAdditionals()

# save shapes
netedit.saveShapes()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 24
0
# Change parameter 8 with a valid value (valid)
netedit.modifyAttribute(8, "berlin_icon.ico")

# Change parameter 9 with a non valid value (dummy)
netedit.modifyAttribute(9, "dummyAngle")

# Change parameter 9 with a valid value (negative)
netedit.modifyAttribute(9, "-12")

# Change parameter 9 with a valid value (> 360º)
netedit.modifyAttribute(9, "500")

# Change parameter 9 with a valid value (> 360º)
netedit.modifyAttribute(9, "30")

# Change boolean parameter 3
netedit.modifyShapeDefaultBoolValue(10)

# Check undos and redos
netedit.undo(match, 25)
netedit.redo(match, 25)

# save shapes
netedit.saveShapes()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 25
0
# Change parameter 9 with a valid value (> 360)
netedit.modifyAttribute(8, "30")

# Change parameter 9 with a non valid value (dummy)
netedit.modifyAttribute(9, "dummyGEO")

# Change parameter 9 with a non valid value (empty)
netedit.modifyAttribute(9, "")

# Change parameter 9 with a valid value 
netedit.modifyAttribute(9, "3.73,74.30")

# Change boolean parameter GEO
netedit.modifyShapeDefaultBoolValue(10)

# Change boolean parameter block
netedit.modifyShapeDefaultBoolValue(12)

# Check undos and redos
netedit.undo(match, 26)
netedit.redo(match, 26)

# save shapes
netedit.saveShapes()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 26
0
# Change parameter 5 with a non valid value (negative)
netedit.modifyAttribute(5, "-5")

# Change parameter 5 with a valid value
netedit.modifyAttribute(5, "4")

# Change parameter 6 with a non valid value (dummy)
netedit.modifyAttribute(6, "dummySpeedTreshold")

# Change parameter 6 with a non valid value (negative)
netedit.modifyAttribute(6, "-12.1")

# Change parameter 6 with a valid value
netedit.modifyAttribute(6, "6.3")

# go to a empty area
netedit.leftClick(match, 0, 0)

# Check undos and redos
netedit.undo(match, 21)
netedit.redo(match, 21)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 27
0
# try to create create vaporizer
netedit.leftClick(match, 250, 220)

# set valid end
netedit.modifyAdditionalDefaultValue(3, "20")

# create vaporizer
netedit.leftClick(match, 250, 220)

# change default start (Invalid, end > startTime)
netedit.modifyAdditionalDefaultValue(2, "50")

# try to create invalid vaporizer (show warning)
netedit.leftClick(match, 250, 220)

# change default end (valid))
netedit.modifyAdditionalDefaultValue(2, "100")

# Check undo redo
netedit.undo(match, 4)
netedit.redo(match, 4)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 28
0
# Set invalid angle
netedit.modifyAttribute(7, "dummyAngle")

# Set valid angle
netedit.modifyAttribute(7, "180")

# Change use GEO
netedit.modifyShapeDefaultBoolValue(9)

# Change block move
netedit.modifyShapeDefaultBoolValue(11)

# go to select mode
netedit.selectMode()

# clear selection
netedit.selectionClear()

# Check undos and redos
netedit.undo(match, 14)
netedit.redo(match, 14)

# save shapes
netedit.saveShapes()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 29
0
# Change parameter 6 with a non valid value 3
netedit.modifyAttribute(7, "2")

# Change parameter 6 with a valid value
netedit.modifyAttribute(7, "0.90")

# Change parameter 7 (bool)
netedit.modifyBoolAttribute(8)

# Change parameter 8 with a non valid value 1
netedit.modifyAttribute(9, "dummyChargeDelay")

# Change parameter 8 with a non valid value 2
netedit.modifyAttribute(9, "-10")

# Change parameter 8 with a valid value
netedit.modifyAttribute(9, "3")

# Check undos and redos
netedit.undo(match, 18)
netedit.redo(match, 18)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 30
0
# Change boolean parameter 10
netedit.modifyShapeDefaultBoolValue(10)

# Change parameter 11 with a non valid value (dummy)
netedit.modifyAttribute(11, "dummyAngle")

# Change parameter 11 with a valid value (negative)
netedit.modifyAttribute(11, "-12")

# Change parameter 11 with a valid value (> 360)
netedit.modifyAttribute(11, "500")

# Change parameter 11 with a valid value
netedit.modifyAttribute(11, "30")

# Change boolean parameter block
netedit.modifyShapeDefaultBoolValue(13)

# Check undos and redos
netedit.undo(match, 28)
netedit.redo(match, 28)

# save shapes
netedit.saveShapes()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 31
0
# change use geo
netedit.modifyBoolAttribute(8)

# change block move
netedit.modifyBoolAttribute(10)

# change block shape
netedit.modifyBoolAttribute(11)

# change close
netedit.modifyBoolAttribute(12)

# go to select mode
netedit.selectMode()

# clear selection
netedit.selectionClear()

# Check undos and redos
netedit.undo(match, 15)
netedit.redo(match, 15)

# save shapes
netedit.saveShapes()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 32
0
netedit.cancelEdge()

# disable chain mode
netedit.changeChainOption()

# create a complex intersection
netedit.leftClick(match, 300, 250)
netedit.leftClick(match, 300, 150)

netedit.leftClick(match, 300, 250)
netedit.leftClick(match, 400, 250)

netedit.leftClick(match, 300, 250)
netedit.leftClick(match, 300, 350)

netedit.leftClick(match, 300, 250)
netedit.leftClick(match, 200, 250)

# rebuild network
netedit.rebuildNetwork()

# Check undo and redo
netedit.undo(match, 20)
netedit.redo(match, 20)

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 33
0
# try chargingStation in mode "reference right" (Warning)
netedit.leftClick(match, 110, 250)

# enable force position
netedit.modifyAdditionalDefaultBoolValue(10)

# change reference to "reference left"
netedit.modifyAdditionalDefaultValue(7, "reference left")

# create a chargingStation in mode "reference left" forcing poisition
netedit.leftClick(match, 500, 250)

# change reference to "reference right"
netedit.modifyAdditionalDefaultValue(7, "reference right")

# create a chargingStation in mode "reference right" forcing position
netedit.leftClick(match, 110, 250)

# Check undo redo
netedit.undo(match, 6)
netedit.redo(match, 6)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess, False, False)
Esempio n. 34
0
neteditTestRoot = os.path.join(os.environ.get('TEXTTEST_HOME', testRoot), 'netedit')
sys.path.append(neteditTestRoot)
import neteditTestFunctions as netedit

# Open netedit
neteditProcess, match = netedit.setupAndStart(neteditTestRoot, False)

# Rebuild network
netedit.rebuildNetwork()

# zoom in central node
netedit.zoomIn(match.getTarget().offset(325, 225), 10)

# set crossing mode
type("d")

# delete first crossing
click(match.getTarget().offset(250, 225))

# delete second crossing
click(match.getTarget().offset(385, 225))

# check undo redo
netedit.undo(match, 2)
netedit.redo(match, 2)

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)
Esempio n. 35
0
# inspect eleven node
netedit.leftClick(match, 350, 275)

# change radio
netedit.modifyAttribute(5, "2")

# change keep clear
netedit.modifyBoolAttribute(6)

# rebuild network
netedit.rebuildNetwork()

# Check undo
netedit.undo(match, 22)

# rebuild network
netedit.rebuildNetwork()

# Check redo
netedit.redo(match, 22)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 36
0
# Change parameter 8 with a non valid value
netedit.modifyAttribute(8, "-12.1")

# Change parameter 8 with a valid value
netedit.modifyAttribute(8, "6.3")

# Change parameter 9 with a non valid value
netedit.modifyAttribute(9, "dummyJamThreshold")

# Change parameter 9 with a non valid value
netedit.modifyAttribute(9, "-8")

# Change parameter 9 with a valid value
netedit.modifyAttribute(9, "12.5")

# go to a empty area
click(match)

# Check undos and redos
netedit.undo(match, 23)
netedit.redo(match, 23)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess, False, False)
Esempio n. 37
0
# Change parameter 3 with a non valid value (dummy)
netedit.modifyAttribute(4, "")

# Change parameter 3 with a valid value
netedit.modifyAttribute(4, "OwnOutput.txt")

# Change parameter 4 with a non valid value (dummy)
netedit.modifyAttribute(4, "dummy")

# Change parameter 4 with a non valid value (negative)
netedit.modifyAttribute(4, "-5")

# Change parameter 4 with a valid value
netedit.modifyAttribute(4, "20")

# click over an empty area
netedit.leftClick(match, 0, 0)

# Check undos and redos
netedit.undo(match, 13)
netedit.redo(match, 13)

# save additionals
netedit.saveAdditionals()

# save network
netedit.saveNetwork()

# quit netedit
netedit.quit(neteditProcess)
Esempio n. 38
0
# Change parameter 8 with a non valid value
netedit.modifyAttribute(parametersReference, 8, "-12.1")

# Change parameter 8 with a valid value
netedit.modifyAttribute(parametersReference, 8, "6.3")

# Change parameter 9 with a non valid value
netedit.modifyAttribute(parametersReference, 9, "dummyJamThreshold")

# Change parameter 9 with a non valid value
netedit.modifyAttribute(parametersReference, 9, "-8")

# Change parameter 9 with a valid value
netedit.modifyAttribute(parametersReference, 9, "12.5")

# go to a empty area
click(match);

# Check undos and redos
netedit.undo(match, 23)
netedit.redo(match, 23)

# save additionals
netedit.saveAdditionals()

# save newtork
netedit.saveNetwork()

# quit netedit 
netedit.quit(neteditProcess, False, False)