From 10dd49958c96f86c8247c715bd20a6681afc1d8b Mon Sep 17 00:00:00 2001 From: Christian Clason Date: Sun, 24 Dec 2023 12:52:21 +0100 Subject: chore(tests): consistent captures --- tests/query/highlights/python/pattern_matching.py | 34 +++++++++++------------ 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'tests/query/highlights/python') diff --git a/tests/query/highlights/python/pattern_matching.py b/tests/query/highlights/python/pattern_matching.py index 2d7d7d0c0..cd359a48f 100644 --- a/tests/query/highlights/python/pattern_matching.py +++ b/tests/query/highlights/python/pattern_matching.py @@ -1,51 +1,51 @@ match command.split(): -# ^ conditional +# ^ @conditional case ["quit"]: - # ^ conditional + # ^ @conditional print("Goodbye!") quit_game() case ["look"]: - # ^ conditional + # ^ @conditional current_room.describe() case ["get", obj]: - # ^ conditional + # ^ @conditional character.get(obj, current_room) case ["go", direction]: - # ^ conditional + # ^ @conditional current_room = current_room.neighbor(direction) # The rest of your commands go here match command.split(): -# ^ conditional +# ^ @conditional case ["drop", *objects]: - # ^ conditional + # ^ @conditional for obj in objects: character.drop(obj, current_room) match command.split(): -# ^ conditional +# ^ @conditional case ["quit"]: ... # Code omitted for brevity case ["go", direction]: pass case ["drop", *objects]: pass case _: print(f"Sorry, I couldn't understand {command!r}") - # ^^ @function.macro + # ^^ @@function.macro match command.split(): -# ^ conditional +# ^ @conditional case ["north"] | ["go", "north"]: - # ^ conditional + # ^ @conditional current_room = current_room.neighbor("north") case ["get", obj] | ["pick", "up", obj] | ["pick", obj, "up"]: - # ^ conditional + # ^ @conditional pass match = 2 -# ^ variable +# ^ @variable match, a = 2, 3 -# ^ variable +# ^ @variable match: int = secret -# ^ variable +# ^ @variable x, match: str = 2, "hey, what's up?" -# <- variable -# ^ variable +# <- @variable +# ^ @variable -- cgit v1.2.3-70-g09d2