mirror of
https://github.com/enzet/map-machine.git
synced 2025-05-29 00:46:27 +02:00
Add unwrapped test for element.
This commit is contained in:
parent
c58cbfe4f9
commit
dba0caf88f
1 changed files with 11 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
|||
"""
|
||||
Test command line commands.
|
||||
"""
|
||||
import argparse
|
||||
from pathlib import Path
|
||||
from subprocess import PIPE, Popen
|
||||
|
||||
|
@ -10,7 +11,7 @@ __email__ = "me@enzet.ru"
|
|||
from xml.etree import ElementTree
|
||||
from xml.etree.ElementTree import Element
|
||||
|
||||
from map_machine.ui.cli import COMMAND_LINES
|
||||
from map_machine.ui.cli import COMMAND_LINES, parse_arguments
|
||||
|
||||
LOG: bytes = (
|
||||
b"INFO Constructing ways...\n"
|
||||
|
@ -122,6 +123,15 @@ def test_element() -> None:
|
|||
assert (Path("out") / "element.svg").is_file()
|
||||
|
||||
|
||||
def test_unwrapped_element() -> None:
|
||||
arguments: argparse.Namespace = parse_arguments(
|
||||
["map_machine"] + COMMAND_LINES["element"]
|
||||
)
|
||||
from map_machine.element.single import draw_element
|
||||
|
||||
draw_element(arguments)
|
||||
|
||||
|
||||
def test_tile() -> None:
|
||||
"""Test `tile` command."""
|
||||
run(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue