Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/software/ai/hl/stp/play/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Expand Down Expand Up @@ -214,7 +214,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Expand Down Expand Up @@ -270,7 +270,7 @@ py_test(
"//proto:software_py_proto",
"//proto:tbots_py_proto",
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/ball_placement/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ py_test(
tags = ["exclusive"],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
from proto.import_all_protos import *
from proto.ssl_gc_common_pb2 import Team
from proto.message_translation.tbots_protobuf import create_world_state
from software.simulated_tests.ball_enters_region import (
from software.simulated_tests.pytest_validations.ball_enters_region import (
BallAlwaysStaysInRegion,
BallEventuallyEntersRegion,
)
from software.simulated_tests.robot_enters_region import RobotEventuallyExitsRegion
from software.simulated_tests.pytest_validations.robot_enters_region import (
RobotEventuallyExitsRegion,
)
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/crease_defense/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: "//software/simulated_tests/pytest/validations:all_validations" instead? Or "//software/simulated_tests/pytest:validations" Or "//software/simulated_tests/python/validations:all_validations"

requirement("pytest"),
],
)
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/defense/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Expand Down
4 changes: 2 additions & 2 deletions src/software/ai/hl/stp/play/defense/defense_play_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.friendly_has_ball_possession import (
from software.simulated_tests.pytest_validations.ball_enters_region import *
from software.simulated_tests.pytest_validations.friendly_has_ball_possession import (
FriendlyEventuallyHasBallPossession,
)
from proto.message_translation.tbots_protobuf import create_world_state
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/enemy_ball_placement/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ py_test(
tags = ["exclusive"],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName
from software.simulated_tests.robot_enters_placement_region import *
from software.simulated_tests.pytest_validations.robot_enters_placement_region import *
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/enemy_free_kick/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,11 @@
import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName

from software.simulated_tests.or_validation import OrValidation
from software.simulated_tests.pytest_validations.or_validation import OrValidation

from software.simulated_tests.ball_moves_from_rest import (
BallEventuallyMovesFromRest,
)
from software.simulated_tests.friendly_team_scored import *
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.robot_enters_region import (
from software.simulated_tests.pytest_validations.friendly_team_scored import *
from software.simulated_tests.pytest_validations.ball_enters_region import *
from software.simulated_tests.pytest_validations.robot_enters_region import (
RobotEventuallyEntersRegion,
RobotNeverEntersRegion,
)
Expand Down Expand Up @@ -136,11 +133,14 @@ def setup(*args):
RobotNeverEntersRegion(
regions=[tbots_cpp.Circle(ball_initial_pos, 0.05)]
),
BallEventuallyMovesFromRest(position=ball_initial_pos),
BallEventuallyExitsRegion(
regions=[tbots_cpp.Circle(ball_initial_pos, 0.05)]
),
]
)
]
]

# Eventually Validation
eventually_validation_sequence_set = [
[RobotEventuallyEntersRegion(regions=[tbots_cpp.Circle(ball_initial_pos, 1)])]
Expand Down
3 changes: 1 addition & 2 deletions src/software/ai/hl/stp/play/example/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:speed_threshold_helpers",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
4 changes: 2 additions & 2 deletions src/software/ai/hl/stp/play/example/example_play_test.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import software.python_bindings as tbots_cpp
from software.simulated_tests.robot_enters_region import (
from software.simulated_tests.pytest_validations.robot_enters_region import (
NumberOfRobotsEventuallyExitsRegion,
NumberOfRobotsEventuallyEntersRegion,
)
from software.simulated_tests.robot_speed_threshold import *
from software.simulated_tests.pytest_validations.robot_speed_threshold import *
from proto.message_translation.tbots_protobuf import create_world_state
from proto.ssl_gc_common_pb2 import Team
from proto.play_pb2 import Play, PlayName
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/free_kick/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ py_test(
tags = ["exclusive"],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
import pytest

import software.python_bindings as tbots_cpp

from proto.import_all_protos import *

from proto.play_pb2 import Play, PlayName
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.friendly_team_scored import *
from proto.message_translation.tbots_protobuf import create_world_state
from proto.ssl_gc_common_pb2 import Team

from proto.message_translation.tbots_protobuf import create_world_state
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
Expand Down
3 changes: 1 addition & 2 deletions src/software/ai/hl/stp/play/halt_play/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:speed_threshold_helpers",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would probably keep the library name as just validations since the all doesn't really add anything to the semantics

requirement("pytest"),
],
)
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/halt_play/halt_play_test.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import software.python_bindings as tbots_cpp
from software.simulated_tests.robot_speed_threshold import *
from software.simulated_tests.pytest_validations.robot_speed_threshold import *
from proto.message_translation.tbots_protobuf import create_world_state
from proto.ssl_gc_common_pb2 import Team
from software.simulated_tests.simulated_test_fixture import (
Expand Down
11 changes: 5 additions & 6 deletions src/software/ai/hl/stp/play/kickoff_play_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,15 @@

import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName
from software.simulated_tests.robot_enters_region import *
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.ball_moves_from_rest import *
from software.simulated_tests.pytest_validations.robot_enters_region import *
from software.simulated_tests.pytest_validations.ball_enters_region import *
from proto.import_all_protos import *
from proto.message_translation.tbots_protobuf import create_world_state
from proto.ssl_gc_common_pb2 import Team
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
from software.simulated_tests.or_validation import OrValidation
from software.simulated_tests.pytest_validations.or_validation import OrValidation


@pytest.mark.parametrize("is_friendly_test", [True, False])
Expand Down Expand Up @@ -80,8 +79,8 @@ def setup(*args):
# Always Validation
always_validation_sequence_set = [[]]

ball_moves_at_rest_validation = BallAlwaysMovesFromRest(
position=tbots_cpp.Point(0, 0), threshold=0.05
ball_moves_at_rest_validation = BallNeverEntersRegion(
regions=[tbots_cpp.Circle(tbots_cpp.Point(0, 0), 0.05)]
)

expected_center_circle_or_validation_set = [
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/offense/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
9 changes: 4 additions & 5 deletions src/software/ai/hl/stp/play/offense/offense_play_test.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName

from software.simulated_tests.excessive_dribbling import NeverExcessivelyDribbles
from software.simulated_tests.friendly_team_scored import *
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.friendly_has_ball_possession import *
from software.simulated_tests.pytest_validations.friendly_team_scored import *
from software.simulated_tests.pytest_validations.ball_enters_region import *
from software.simulated_tests.pytest_validations.friendly_has_ball_possession import *
from software.simulated_tests.pytest_validations.excessive_dribbling import *
from proto.message_translation.tbots_protobuf import create_world_state
from proto.ssl_gc_common_pb2 import Team
from software.simulated_tests.simulated_test_fixture import (
Expand Down
12 changes: 7 additions & 5 deletions src/software/ai/hl/stp/play/passing_sim_test.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
import pytest
import math
import software.python_bindings as tbots_cpp
import math
from proto.import_all_protos import *
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
from proto.message_translation.tbots_protobuf import create_world_state
from software.simulated_tests.friendly_receives_ball_slow import (
from software.simulated_tests.pytest_validations.friendly_receives_ball_slow import (
FriendlyAlwaysReceivesBallSlow,
)
from software.simulated_tests.friendly_has_ball_possession import (
from software.simulated_tests.pytest_validations.friendly_has_ball_possession import (
FriendlyEventuallyHasBallPossession,
)
from software.simulated_tests.ball_moves_in_direction import BallMovesForwardInRegions
from software.simulated_tests.ball_enters_region import (
from software.simulated_tests.pytest_validations.ball_moves_in_direction import (
BallMovesForwardInRegions,
)
from software.simulated_tests.pytest_validations.ball_enters_region import (
BallEventuallyExitsRegion,
BallEventuallyEntersRegion,
)
Expand Down
2 changes: 1 addition & 1 deletion src/software/ai/hl/stp/play/shoot_or_chip_play_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

import software.python_bindings as tbots_cpp
from proto.play_pb2 import Play, PlayName
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.pytest_validations.ball_enters_region import *
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
Expand Down
3 changes: 1 addition & 2 deletions src/software/ai/hl/stp/tactic/crease_defender/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:speed_threshold_helpers",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Original file line number Diff line number Diff line change
@@ -1,18 +1,28 @@
import pytest

import software.python_bindings as tbots_cpp
from software.simulated_tests.robot_enters_region import *
from software.simulated_tests.ball_enters_region import *
from software.simulated_tests.ball_moves_in_direction import *
from software.simulated_tests.friendly_has_ball_possession import *
from software.simulated_tests.ball_speed_threshold import *
from software.simulated_tests.robot_speed_threshold import *
from software.simulated_tests.excessive_dribbling import *

from proto.import_all_protos import (
BallStealMode,
CreaseDefenderAlignment,
CreaseDefenderTactic,
MaxAllowedSpeedMode,
)
from proto.message_translation.tbots_protobuf import create_world_state
from software.simulated_tests.pytest_validations.ball_is_off_ground import (
BallIsAlwaysOnGround,
BallIsEventuallyOffGround,
)
from software.simulated_tests.pytest_validations.excessive_dribbling import (
NeverExcessivelyDribbles,
)
from software.simulated_tests.pytest_validations.robot_enters_region import (
RobotEventuallyEntersRegion,
RobotNeverEntersRegion,
)
from proto.import_all_protos import *
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
from software.simulated_tests.ball_is_off_ground import *
from proto.message_translation.tbots_protobuf import create_world_state


@pytest.mark.parametrize(
Expand Down
3 changes: 1 addition & 2 deletions src/software/ai/hl/stp/tactic/dribble/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:speed_threshold_helpers",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
import pytest

import software.python_bindings as tbots_cpp
from software.simulated_tests.excessive_dribbling import (
NeverExcessivelyDribbles,

from proto.import_all_protos import *
from proto.message_translation.tbots_protobuf import DribbleTactic, create_world_state
from software.simulated_tests.pytest_validations.excessive_dribbling import (
EventuallyStartsExcessivelyDribbling,
)
from proto.message_translation.tbots_protobuf import (
WorldState,
AssignedTacticPlayControlParams,
DribbleTactic,
NeverExcessivelyDribbles,
)
from software.simulated_tests.simulated_test_fixture import (
pytest_main,
)
from proto.message_translation.tbots_protobuf import create_world_state


@pytest.mark.parametrize(
Expand Down
3 changes: 1 addition & 2 deletions src/software/ai/hl/stp/tactic/goalie/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,7 @@ py_test(
],
deps = [
"//software:conftest",
"//software/simulated_tests:speed_threshold_helpers",
"//software/simulated_tests:validation",
"//software/simulated_tests/pytest_validations:all_validations",
requirement("pytest"),
],
)
Loading