mirror of
https://github.com/enzet/map-machine.git
synced 2025-05-29 08:56:27 +02:00
Rename element
command to draw
.
And add node drawing.
This commit is contained in:
parent
6dd9bc27e8
commit
692997f54a
7 changed files with 33 additions and 29 deletions
|
@ -111,21 +111,21 @@ def test_mapcss() -> None:
|
|||
assert (out_path / "icons" / "LICENSE").is_file()
|
||||
|
||||
|
||||
def test_element() -> None:
|
||||
"""Test `element` command."""
|
||||
def test_draw() -> None:
|
||||
"""Test `draw` command."""
|
||||
run(
|
||||
COMMAND_LINES["element"],
|
||||
b"INFO Element is written to out/element.svg.\n",
|
||||
COMMAND_LINES["draw"],
|
||||
LOG + b"INFO Map is drawn to out/element.svg.\n",
|
||||
)
|
||||
assert (OUTPUT_PATH / "element.svg").is_file()
|
||||
|
||||
|
||||
def test_unwrapped_element() -> None:
|
||||
def test_unwrapped_draw() -> None:
|
||||
"""Test `element` command from inside the project."""
|
||||
arguments: argparse.Namespace = parse_arguments(
|
||||
["map_machine"] + COMMAND_LINES["element"]
|
||||
["map_machine"] + COMMAND_LINES["draw"]
|
||||
)
|
||||
from map_machine.element.node import draw_element
|
||||
from map_machine.element.element import draw_element
|
||||
|
||||
draw_element(arguments)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue