mirror of
https://github.com/enzet/map-machine.git
synced 2025-05-21 21:16:24 +02:00
Speed up tests.
Load scheme and shape extractor just once for a test group.
This commit is contained in:
parent
1b40087b18
commit
c5bb1529f5
2 changed files with 9 additions and 7 deletions
|
@ -8,13 +8,14 @@ from typing import List
|
|||
from roentgen.scheme import Scheme
|
||||
from roentgen.text import Label
|
||||
|
||||
SCHEME: Scheme = Scheme("scheme/default.yml")
|
||||
|
||||
|
||||
def construct_labels(tags) -> List[Label]:
|
||||
"""
|
||||
Construct labels from OSM node tags.
|
||||
"""
|
||||
scheme = Scheme("scheme/default.yml")
|
||||
return scheme.construct_text(tags, True)
|
||||
return SCHEME.construct_text(tags, "all")
|
||||
|
||||
|
||||
def test_1_label() -> None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue