diff --git a/sim/tests/endToEndTests/test_end_to_end.json b/sim/tests/endToEndTests/test_end_to_end.json index a115652401d455d1573824ca45a41cbee9419ca0..49973db7973a653a1a6aa3b7acbe2735b8f2518b 100644 --- a/sim/tests/endToEndTests/test_end_to_end.json +++ b/sim/tests/endToEndTests/test_end_to_end.json @@ -1,7 +1,41 @@ { "config_sets": { "Generic": [ - "Common" + "ADAS_AEB_PreventingCollisionWithObstacle", + "ByEntityCondition_RelativeLane", + "ByEntityCondition_RelativeSpeed", + "ByEntityCondition_RoadPosition", + "ByEntityCondition_TimeHeadway", + "ByEntityCondition_TimeToCollision", + "Common", + "DynamicOSMPSensorDataToTUStepper", + "DynamicSSPStepper", + "LightStateAction", + "OSCAction_DoubleCubicLaneChangeLeft_Absolute", + "OSCAction_DoubleCubicLaneChangeLeft_Relative", + "OSCAction_DoubleCubicLaneChangeRight_Absolute", + "OSCAction_DoubleCubicLaneChangeRight_Relative", + "OSCAction_SpeedAction_Step", + "OSCAction_TeleportAction", + "StaticOSMPSensorDataToTUStepper", + "StaticSSPStepper", + "Sensor_Latency", + "SupplementaryTrafficSigns", + "TrafficJam" + ], + "DISABLED_Generic": [ + "ADAS_AEB_CutIn", + "ADAS_AEB_PreventingCollisionWithObstacleInCurve", + "ADAS_V2X", + "AFDM_TJunction", + "LocalizationOnJunction", + "ObjectAboveRoad", + "ObjectOfTypeRoadMark", + "OSCAction_ActivateController", + "OSCAction_TrafficSinkAction", + "Pedestrian_Trajectory", + "TurningRates", + "TrafficLight" ], "ByEntityCondition": [ "ByEntityCondition_RelativeLane", @@ -51,7 +85,9 @@ "Sensor_Failure_1_Car2X" ], "Sensor_Failure_0.5": [ - "Sensor_Failure_0.5_Geometric2D", + "Sensor_Failure_0.5_Geometric2D" + ], + "DISABLED_Sensor_Failure_0.5": [ "Sensor_Failure_0.5_Car2X" ], "PCM": [ @@ -75,16 +111,16 @@ "OSCAction_ActivateController": [ "OSCAction_ActivateController" ], - "OSCAction_SinusoidalLaneChange": [ - "OSCAction_SinusoidalLaneChangeLeft_Absolute", - "OSCAction_SinusoidalLaneChangeRight_Absolute", - "OSCAction_SinusoidalLaneChangeLeft_Relative", - "OSCAction_SinusoidalLaneChangeRight_Relative" + "OSCAction_CubicLaneChange": [ + "OSCAction_CubicLaneChangeLeft_Absolute", + "OSCAction_CubicLaneChangeRight_Absolute", + "OSCAction_CubicLaneChangeLeft_Relative", + "OSCAction_CubicLaneChangeRight_Relative" ], - "OSCAction_DoubleSinusoidalLaneChange": [ - "OSCAction_DoubleSinusoidalLaneChangeLeft_Absolute", - "OSCAction_DoubleSinusoidalLaneChangeLeft_Relative", - "OSCAction_DoubleSinusoidalLaneChangeRight_Relative" + "OSCAction_DoubleCubicLaneChange": [ + "OSCAction_DoubleCubicLaneChangeLeft_Absolute", + "OSCAction_DoubleCubicLaneChangeLeft_Relative", + "OSCAction_DoubleCubicLaneChangeRight_Relative" ], "OSCAction_SpeedAction_Absolute": [ "OSCAction_SpeedAction_Absolute" @@ -95,18 +131,12 @@ "OSCAction_SpeedAction_Step": [ "OSCAction_SpeedAction_Step" ], - "OSCAction_RemoveAgent": [ - "OSCAction_RemoveAgent" - ], "OSCAction_TeleportAction": [ "OSCAction_TeleportAction" ], "OSCAction_TrafficSinkAction": [ "OSCAction_TrafficSinkAction" ], - "Delay": [ - "OSCAction_RemoveAgentWithDelay" - ], "TUStepCtrl": [ "StaticOSMPSensorDataToTUStepper", @@ -131,6 +161,480 @@ "duration": 30, "invocations": 3, "determinism": true + }, + "generic_fmu_linux64": { + "config_sets": [ + "FMU" + ], + "duration": 30, + "invocations": 1, + "parameterization": { + "file": "systemConfigFmuActuator.xml", + "xpath": "//value[../id='FmuPath']", + "values": [ + "resources/linux64/dummyFMU1_StaticFMUActuator.fmu", + "resources/linux64/dummyFMU2_StaticFMUActuator.fmu" + ] + } + }, + "DISABLED_generic_fmu_win64": { + "config_sets": [ + "FMU" + ], + "duration": 30, + "invocations": 1, + "parameterization": { + "file": "systemConfigFmuActuator.xml", + "xpath": "//value[../id='FmuPath']", + "values": [ + "resources/win64/dummyFMU1_StaticFMUActuator.fmu", + "resources/win64/dummyFMU2_StaticFMUActuator.fmu" + ] + } + }, + "FMU_CustomCommandAction": { + "config_sets": [ + "FMU_CustomCommandAction" + ], + "duration": 1, + "invocations": 1, + "description": "Check if the XPosition(BB Center) of the ego agent is as expected", + "queries": [ + "count(AgentId | XPosition == 100 and Timestep == 100 and AgentId == 0) == 1" + ], + "success_rate": 1.0 + }, + "DISABLED_FMU_FollowPathAction": { + "config_sets": [ + "FMU_FollowPathAction" + ], + "duration": 1, + "invocations": 1, + "description": "Check if the XPosition_RA and YPosition_RA of the agent is as expected", + "queries": [ + "count(AgentId | XPosition_RA == 200.50 and YPosition_RA == 5.425 and Timestep == 100 and AgentId == 0) == 1" + ], + "success_rate": 1.0 + }, + "DISABLED_FMU_FollowTrajectoryAction": { + "config_sets": [ + "FMU_FollowTrajectoryAction" + ], + "duration": 5, + "invocations": 1, + "description": "Check if the XPosition_RA and YPosition_RA of the ego agent is as expected", + "queries": [ + "count(AgentId | XPosition_RA == 200.50 and YPosition_RA == 5.425 and Timestep == 100 and AgentId == 0) == 1" + ], + "success_rate": 1.0 + }, + "FMU_SpeedAction": { + "config_sets": [ + "FMU_SpeedAction" + ], + "duration": 1, + "invocations": 1, + "description": "Check if the speed of the ego agent is as expected", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 100 and Velocity_RA == 20.0) == 1" + ], + "success_rate": 1.0 + }, + "DISABLED_ADAS_AEB": { + "config_sets": [ + "ADAS_AEB_PreventingCollisionWithObstacle" + ], + "duration": 30, + "invocations": 1, + "description": "AEB triggers if agent cannot stop", + "queries": [ + "mean(Velocity_RA | AgentId == 0 and PositionRoute > 285 and PositionRoute < 295) < 28.5" + ], + "success_rate": 1 + }, + "DISABLED_ADAS_Static_AEB": { + "config_sets": [ + "ADAS_Static_AEB_PreventingCollisionWithObstacle" + ], + "duration": 30, + "invocations": 1, + "description": "Static AEB Acting stage triggers with obstacle", + "queries": [ + "count(AgentId | #(Algorithm_AutonomousEmergencyBraking):ComponentState=='Acting') >= 1" + ], + "success_rate": 1 + }, + "DISABLED_ADAS_AEB_InCurve": { + "config_sets": [ + "ADAS_AEB_PreventingCollisionWithObstacleInCurve" + ], + "duration": 20, + "invocations": 1, + "description": "AEB Acting stage triggers with obstacle in curve", + "queries": [ + "count(AgentId | #(Algorithm_AutonomousEmergencyBraking):ComponentState=='Acting') >= 1" + ], + "success_rate": 1 + }, + "DISABLED_ADAS_AEB_CutIn_TriggersAndPreventsCollision": { + "config_sets": [ + "ADAS_AEB_CutIn" + ], + "duration": 30, + "invocations": 20, + "description": "AEB triggers and prevents collision", + "queries": [ + "count(AgentId | AgentId == 0 and #(Algorithm_AutonomousEmergencyBraking):ComponentState=='Acting') >= 1", + "count(AgentId | AgentId == 0 and #(Collision) >= 1) == 0" + ], + "success_rate": 0.95 + }, + "DISABLED_ADAS_V2X": { + "config_sets": [ + "ADAS_V2X" + ], + "duration": 20, + "invocations": 1, + "description": "Receiver car2x detects the object within the signal range", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep > 0 and Timestep <= 10000 and Sensor0_DetectedAgents == 'nan') == 39", + "count(AgentId | AgentId == 1 and Timestep > 0 and Timestep <= 10000 and Sensor0_DetectedAgents == 'nan') == 39", + "count(AgentId | AgentId == 0 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == '1') == 134", + "count(AgentId | AgentId == 1 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == '0') == 135", + "count(AgentId | AgentId == 0 and Timestep > 10000 and Timestep <= 20000 and Sensor0_DetectedAgents == 'nan') == 27", + "count(AgentId | AgentId == 1 and Timestep > 10000 and Timestep <= 20000 and Sensor0_DetectedAgents == 'nan') == 26" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "DISABLED_ByEntityCondition": { + "config_sets": [ + "ByEntityCondition" + ], + "duration": 11, + "invocations": 1, + "description": "Agent performs left Cubic lane change to lane id -3 if entity condition is met", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep >= 10000 and Lane == -3) > 0" + ], + "success_rate": 1.0 + }, + "DISABLED_LightStateAction": { + "config_sets": [ + "LightStateAction" + ], + "duration": 10, + "invocations": 1, + "description": "IndicatorState for Ego is set to left", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep <= 3000 and IndicatorState == 1) == 0", + "count(AgentId | AgentId == 0 and Timestep > 3000 and Timestep <= 6000 and IndicatorState == 1) > 0", + "count(AgentId | AgentId == 0 and Timestep > 6000 and IndicatorState == 1) == 0" + ], + "success_rate": 1.0 + }, + "DISABLED_LocalizationOnJunction": { + "config_sets": [ + "LocalizationOnJunction" + ], + "duration": 45, + "invocations": 10, + "description": "Agent is always located on defined route", + "queries": [ + "count(Road | Road !='R1' and Road !='R1_3' and Road !='R3') == 0" + ], + "success_rate": 0.99 + }, + "DISABLED_NoCollisionWithObject": { + "config_sets": [ + "NoCollisionWithObject" + ], + "duration": 5, + "invocations": 1, + "description": "No collision with the object", + "queries": [ + "count(AgentId | #(Collision) >= 1) == 0" + ], + "success_rate": 1.0 + }, + "DISABLED_OSCAction_ActivateController":{ + "config_sets": [ + "OSCAction_ActivateController" + ], + "duration": 2, + "invocations": 1, + "description": "Controllers of ego change", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 600 and #(ActiveComponentChange):LongitudinalController=='Dynamics_Scenario') == 1", + "count(AgentId | AgentId == 0 and Timestep == 1600 and #(ActiveComponentChange):LongitudinalController=='AlgorithmAgentFollowingDriverModel') == 1" + ], + "success_rate": 1.0 + }, + "OSCAction_DoubleLaneChange": { + "config_sets": [ + "OSCAction_DoubleCubicLaneChange" + ], + "duration": 10, + "invocations": 1, + "description": "Agent performs a double lane change", + "queries": [ + "count(AgentId | AgentId == 0 and (Lane-1 != Lane)) == 2" + ], + "success_rate": 1.0 + }, + "DISABLED_OSCAction_FollowRouteAction": { + "config_sets": [ + "OSCAction_FollowRouteAction" + ], + "duration": 33, + "invocations": 10, + "description": "Agent follows the waypoints specified in the FollowRouteAction", + "queries": [ + "count(Road | Road == 2015840166) >= 1" + ], + "success_rate": 1.0 + }, + "DISABLED_OSCAction_TrafficSinkAction": { + "config_sets": [ + "OSCAction_TrafficSinkAction" + ], + "duration": 50.0, + "invocations": 10, + "description": "All agents should despawn before reaching s = 1000", + "queries": [ + "count(AgentId | Timestep > 0 and PositionRoute > 1000) == 0" + ], + "success_rate": 1.0 + }, + "OSCAction_SingleLaneChange": { + "config_sets": [ + "OSCAction_CubicLaneChange" + ], + "duration": 10, + "invocations": 1, + "description": "Agent performs a single lane change", + "queries": [ + "count(AgentId | AgentId == 0 and (Lane-1 != Lane)) == 1" + ], + "success_rate": 1.0 + }, + "OSCAction_SpeedAction_Absolute": { + "config_sets": [ + "OSCAction_SpeedAction_Absolute" + ], + "duration": 5, + "invocations": 1, + "description": "The speed of the ego agent is set to an absolute value via the OpenSCENARIO SpeedAction", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 5000 and VelocityEgo <= 20.1) == 1" + ], + "success_rate": 1.0 + }, + "OSCAction_SpeedAction_Relative": { + "config_sets": [ + "OSCAction_SpeedAction_Relative" + ], + "duration": 10, + "invocations": 1, + "description": "The speed of the ego agent is set to a value relative to the scenario agent via the OpenSCENARIO SpeedAction", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 10000 and VelocityEgo >= 44.9) == 1" + ], + "success_rate": 1.0 + }, + "OSCAction_SpeedAction_Step": { + "config_sets": [ + "OSCAction_SpeedAction_Step" + ], + "duration": 1, + "invocations": 1, + "description": "The speed of the ego agent is set to an absolute value via the OpenSCENARIO SpeedAction", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 600 and VelocityEgo == 20) == 1" + ], + "success_rate": 1.0 + }, + "DISABLED_OSCAction_TeleportAction": { + "config_sets": [ + "OSCAction_TeleportAction" + ], + "duration": 3, + "invocations": 1, + "description": "The position of the ego agent is set to a value defined via the OpenSCENARIO TeleportAction", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep == 100 and XPosition_RA == 0) == 1", + "count(AgentId | AgentId == 0 and Timestep == 1100 and XPosition_RA == 100) == 1", + "count(AgentId | AgentId == 0 and Timestep == 2100 and XPosition_RA >= 199) == 1", + "count(AgentId | AgentId == 0 and Timestep == 2100 and YawAngle == -0.5) == 1" + ], + "success_rate": 1.0 + }, + "DISABLED_Sensor_Delay": { + "config_sets": [ + "Sensor_Delay" + ], + "duration": 5, + "invocations": 1, + "description": "Sensor detects scenario agent with 1 second delay.", + "queries": [ + "count(AgentId | Timestep<=2000 and AgentId==0 and Sensor0_DetectedAgents=='nan') == 21", + "count(AgentId | Timestep==2100 and AgentId==0 and Sensor0_DetectedAgents=='1') == 1" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "Sensor_Latency": { + "config_sets": [ + "Sensor_Latency" + ], + "duration": 5, + "invocations": 20, + "description": "Sensor detects scenario agent with 1 second delay.", + "queries": [ + "count(AgentId | Timestep==1100 and AgentId==0 and Sensor0_DetectedAgents-1=='nan' and Sensor0_DetectedAgents!='nan') == 1" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "DISABLED_PCM": { + "config_sets": [ + "PCM" + ], + "duration": 10, + "invocations": 1, + "description": "Run a pcm case and check if the collision state is as expected", + "queries": [ + "count(AgentId | XPosition_RA > -1.71 and AgentId == 0 and Timestep == 4840) == 1" + ], + "success_rate": 1 + }, + "DISABLED_Sensor_Failure_0": { + "config_sets": [ + "Sensor_Failure_0" + ], + "duration": 20, + "invocations": 1, + "description": "Sensor detects scenario agent in every timestep.", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == '1') == 200", + "count(AgentId | AgentId == 1 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == '0') == 200" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "DISABLED_Sensor_Failure_1": { + "config_sets": [ + "Sensor_Failure_1" + ], + "duration": 20, + "invocations": 1, + "description": "Sensor never detects scenario agent.", + "queries": [ + "count(AgentId | AgentId == 0 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == 'nan') == 200", + "count(AgentId | AgentId == 1 and Timestep > 0 and Timestep <= 20000 and Sensor0_DetectedAgents == 'nan') == 200" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "Sensor_Failure_0.5_Detected": { + "config_sets": [ + "Sensor_Failure_0.5" + ], + "duration": 5, + "invocations": 2, + "description": "Sensor detects scenario agent in some timestep.", + "queries": [ + "count(AgentId | AgentId==0 and Sensor0_DetectedAgents=='1001') > 0" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "Sensor_Failure_0.5_Undetected": { + "config_sets": [ + "Sensor_Failure_0.5" + ], + "duration": 5, + "invocations": 2, + "description": "Sensor does not detect scenario agent in some timestep.", + "queries": [ + "count(AgentId | AgentId==0 and Sensor0_DetectedAgents=='nan') > 0" + ], + "success_rate": 1, + "datatypes": { + "Sensor0_DetectedAgents": "str" + } + }, + "TUStepCtrl": + { + "config_sets": [ + "TUStepCtrl" + ], + "duration": 2, + "invocations": 1, + "description": "Agent is moved by the trafficUpdateStepper", + "queries": [ + "count(AgentId | (AgentId==0 and Timestep > 0 and Velocity_RA > 0.14 and Velocity_RA < 0.142)) == 21" + ], + "success_rate": 1 + }, + "DISABLED_TrafficLightCheckPhases": + { + "config_sets": [ + "TrafficLight" + ], + "duration": 45, + "invocations": 1, + "description": "TrafficLight Events are posted by simulation and cycle through the states", + "queries": [ + "count(AgentId | #(TrafficLight):traffic_light_state=='red') >= 1", + "count(AgentId | #(TrafficLight):traffic_light_state=='yellow') >= 1", + "count(AgentId | #(TrafficLight):traffic_light_state=='green') >= 1", + "count(AgentId | #(TrafficLight):traffic_light_state=='red yellow') >= 1" + ], + "success_rate": 1 + }, + "DISABLED_Dynamics_Scenario": + { + "config": "Dynamics_Scenario", + "duration": 10, + "invocations": 1, + "description": "Agent equiped with Dynamics_Scenario keeps Velocity_RA and t-offset", + "queries": [ + "count(AgentId | AgentId == 0 and Velocity_RA != 43.5) == 0", + "median(TCoordinate | AgentId == 0) == 0.0", + "std(TCoordinate | AgentId == 0) < 0.1", + "min(TCoordinate | AgentId == 0) > -0.2", + "max(TCoordinate | AgentId == 0) < 0.2" + ], + "success_rate": 1 + }, + "DISABLED_ActiveComponentLogging": + { + "config_sets": [ + "ADAS_AEB_PreventingCollisionWithObstacle" + ], + "duration": 30, + "invocations": 1, + "description": "LongitudinalComponent changes from FollowDriver to AEB", + "queries": [ + "count(AgentId | Timestep == 0 and #(ActiveComponentChange):LongitudinalController=='AlgorithmAgentFollowingDriverModel') >= 1", + "count(AgentId | Timestep == 0 and #(ActiveComponentChange):LateralController=='AlgorithmAgentFollowingDriverModel') >= 1", + "count(AgentId | Timestep > 0 and #(ActiveComponentChange):LongitudinalController=='AEB') >= 1", + "count(AgentId | Timestep > 0 and #(ActiveComponentChange):LateralController=='AlgorithmAgentFollowingDriverModel') >= 1" + ], + "success_rate": 1 } } } diff --git a/utils/ci/Jenkinsfile b/utils/ci/Jenkinsfile index 75571c6bc269b66626c277a9482da669f77951ce..0aaafcc609ffdd20900c3d074573e8b1b22c27f0 100644 --- a/utils/ci/Jenkinsfile +++ b/utils/ci/Jenkinsfile @@ -13,7 +13,7 @@ pipeline { agent none parameters { booleanParam(name: 'BUILD_DOCKER_IMAGE', defaultValue: false, description: 'Force docker image (re-)build') - string(name: 'OPTESTRUNNER_URL', defaultValue: 'https://download.eclipse.org/openpass/snapshots/opTestrunner/pytest_optestrunner-1.1-py3-none-any.whl', description: 'URL to download opTestrunner binaries') + string(name: 'OPTESTRUNNER_URL', defaultValue: 'https://ci.eclipse.org/openpass/job/opTestrunner/job/add-invocations-random-seed/1/artifact/repo/plugin/optestrunner/dist/pytest_optestrunner-1.1-py3-none-any.whl', description: 'URL to download opTestrunner binaries') string(name: 'GECCO_URL', defaultValue: 'https://ci.eclipse.org/openpass/job/gecco/view/change-requests/job/MR-3/6/artifact/artifacts/gecco.tar.gz', description: 'URL to download gecco binaries') string(name: 'GTGEN_CLI_URL', defaultValue: 'https://ci.eclipse.org/openpass/job/GT-Gen-Simulator-PreMerge-Gate/view/tags/job/v11.3.0/lastSuccessfulBuild/artifact/artifacts/gtgen-cli_1.1.0_amd64.deb', description: 'URL to download gtgen cli binaries') string(name: 'GTGEN_SIM_URL', defaultValue: 'https://ci.eclipse.org/openpass/job/GT-Gen-Simulator-PreMerge-Gate/view/tags/job/v11.3.0/lastSuccessfulBuild/artifact/artifacts/gtgen-simulator_11.3.0_amd64.deb', description: 'URL to download gtgen simulator binaries') @@ -110,7 +110,8 @@ spec: container('openpass-build') { sh 'bash repo/utils/ci/scripts/pull_gecco.sh' sh 'bash repo/utils/ci/scripts/pull_optestrunner.sh' - sh 'bash repo/utils/ci/scripts/pull_gtgen.sh' + // sh 'bash repo/utils/ci/scripts/pull_gtgen.sh' + sh 'bash repo/utils/ci/scripts/build_gtgen.sh' } } } diff --git a/utils/ci/scripts/55_endtoend.sh b/utils/ci/scripts/55_endtoend.sh index f8c594078087b826e7f64c79d8161c725f4cd156..1e27238b351d2791f810090fe6f484168b6ecec1 100755 --- a/utils/ci/scripts/55_endtoend.sh +++ b/utils/ci/scripts/55_endtoend.sh @@ -30,7 +30,8 @@ if [[ -z "${GECCO_DIR}" ]]; then GECCO_DIR is ${GECCO_DIR}" fi -GTGEN_CLI_PATH="$GTGEN_DIR" +GTGEN_VERSION="add-new-commandline-parameters" +GTGEN_CLI_PATH="$GTGEN_DIR/gt-gen-simulator-${GTGEN_VERSION}/bazel-out/k8-opt/bin/Cli" venv_python_executable="${OP_REPO_DIR}/.env/bin/python3" commonFolder=$GECCO_DIR/gecco/examples/Common diff --git a/utils/ci/scripts/build_gtgen.sh b/utils/ci/scripts/build_gtgen.sh index 71c054222bd59baa1ddd143bd149a9941945b42e..ce1e94d6cf88188f34562015b6e92de7bacdd7da 100755 --- a/utils/ci/scripts/build_gtgen.sh +++ b/utils/ci/scripts/build_gtgen.sh @@ -17,7 +17,7 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" if [[ -z "${GTGEN_DIR}" ]]; then # If not defined, set a default value - GTGEN_DIR="$SCRIPT_DIR/../../../../gtgen_repo" + GTGEN_DIR="$SCRIPT_DIR/../../../../gtgen_cli" echo "WARN: GTGEN_DIR variable is not set. Setting it to: GTGEN_DIR is ${GTGEN_DIR}" fi @@ -27,9 +27,9 @@ rm -rf -- * || { echo "Failed to clean $GTGEN_DIR directory"; exit 1; } bazel --version || { echo "Unable to run bazel"; exit 1; } # ToDo: Make it generic -GTGEN_URL="https://gitlab.eclipse.org/eclipse/openpass/gt-gen-simulator/-/archive/v11.1.0/gt-gen-simulator-v11.1.0.tar.gz" -GTGEN_VERSION="v11.1.0" -GTGEN_CLI_PATH="$GTGEN_DIR/gt-gen-simulator-v11.1.0/bazel-out/k8-opt/bin/Cli" +GTGEN_VERSION="add-new-commandline-parameters" +GTGEN_URL="https://gitlab.eclipse.org/eclipse/openpass/gt-gen-simulator/-/archive/${GTGEN_VERSION}/gt-gen-simulator-${GTGEN_VERSION}.tar.gz" +GTGEN_CLI_PATH="$GTGEN_DIR/gt-gen-simulator-${GTGEN_VERSION}/bazel-out/k8-opt/bin/Cli" CACHEDIR=$GTGEN_DIR # This override the cache folder of bazel @@ -40,14 +40,14 @@ export BAZELISK_HOME="${CACHEDIR}" download_gtgen() { echo "============================== Downloading gt-gen-simulator ==============================" wget $GTGEN_URL || { echo "Unable to download gt-gen-simulator"; exit 1; } - tar -xzvf gt-gen-simulator-v11.1.0.tar.gz || { echo "Unable to checkout $GTGEN_VERSION"; exit 1; } + tar -xzvf gt-gen-simulator-${GTGEN_VERSION}.tar.gz || { echo "Unable to checkout $GTGEN_VERSION"; exit 1; } echo "============================== Cloning Successful ==============================" } #build gtgen build_gtgen() { echo "============================== Building gt-gen-simulator ==============================" - cd "$GTGEN_DIR"/gt-gen-simulator-v11.1.0 || { echo "Unable to change directory into gt-gen-simulator"; exit 1; } + cd "$GTGEN_DIR"/gt-gen-simulator-${GTGEN_VERSION} || { echo "Unable to change directory into gt-gen-simulator"; exit 1; } bazel build --config=gt_gen_release //Cli/... //Simulator/... || { echo "Unable to build gt-gen-simulator"; exit 1; } echo "============================== Extraction Successful ==============================" } diff --git a/utils/ci/scripts/run_gtgen.sh b/utils/ci/scripts/run_gtgen.sh index f859309bfcb720928c853c6cbbc323ba5543ad47..d978b5d754c794dada913020307f823695764cb3 100755 --- a/utils/ci/scripts/run_gtgen.sh +++ b/utils/ci/scripts/run_gtgen.sh @@ -32,7 +32,8 @@ fi mkdir -p "$SCRIPT_DIR/../../../../artifacts" || exit 1 mkdir -p "$SCRIPT_DIR"/../../../../artifacts/config_output || exit 1 -GTGEN_CLI_PATH="$GTGEN_DIR" +GTGEN_VERSION="add-new-commandline-parameters" +GTGEN_CLI_PATH="$GTGEN_DIR/gt-gen-simulator-${GTGEN_VERSION}/bazel-out/k8-opt/bin/Cli" CONFIGS_PATH="$OP_REPO_DIR/sim/contrib/examples/Common" "${GTGEN_CLI_PATH}/gtgen_cli" -t 100 -s Scenario.xosc -d "${CONFIGS_PATH}" || exit 1; \ No newline at end of file