mirror of
https://github.com/enzet/map-machine.git
synced 2025-07-30 23:00:25 +02:00
Rename test to tests; fix equator length.
This commit is contained in:
parent
f744c601d0
commit
ba26c1d4d7
19 changed files with 71 additions and 33 deletions
|
@ -1,8 +1,8 @@
|
|||
#!/bin/sh
|
||||
|
||||
echo "Checking code format with Black..."
|
||||
if ! black -l 80 --check test roentgen roentgen.py; then
|
||||
black -l 80 --diff test roentgen roentgen.py
|
||||
if ! black -l 80 --check tests roentgen roentgen.py; then
|
||||
black -l 80 --diff tests roentgen roentgen.py
|
||||
echo "FAIL"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -13,5 +13,5 @@ echo "Lint with Flake8..."
|
|||
flake8 \
|
||||
--max-line-length=80 \
|
||||
--ignore=E203,W503,ANN002,ANN003,ANN101,ANN102 \
|
||||
--exclude=work,precommit.py,test/test_road.py \
|
||||
--exclude=work,precommit.py,tests/test_road.py \
|
||||
|| { echo "FAIL"; exit 1; }
|
||||
|
|
|
@ -10,8 +10,8 @@ else
|
|||
fi
|
||||
|
||||
echo "Checking code format with Black..."
|
||||
if ! black -l 80 --check test roentgen roentgen.py; then
|
||||
black -l 80 --diff test roentgen roentgen.py
|
||||
if ! black -l 80 --check tests roentgen roentgen.py; then
|
||||
black -l 80 --diff tests roentgen roentgen.py
|
||||
echo "FAIL"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -22,7 +22,7 @@ echo "Lint with Flake8..."
|
|||
flake8 \
|
||||
--max-line-length=80 \
|
||||
--ignore=E203,W503,ANN002,ANN003,ANN101,ANN102 \
|
||||
--exclude=work,precommit.py,test/test_road.py \
|
||||
--exclude=work,precommit.py,tests/test_road.py \
|
||||
|| { echo "FAIL"; exit 1; }
|
||||
|
||||
# Unit tests with pytest.
|
||||
|
@ -33,7 +33,7 @@ pytest -v || { echo "FAIL"; exit 1; }
|
|||
# Integration tests.
|
||||
|
||||
echo "Test render"
|
||||
python3 roentgen.py render -b 10.000,20.000,10.001,20.001 --cache test/data \
|
||||
python3 roentgen.py render -b 10.000,20.000,10.001,20.001 --cache tests/data \
|
||||
|| { echo "FAIL"; exit 1; }
|
||||
grep "natural: tree" out/map.svg || { echo "FAIL"; exit 1; }
|
||||
|
||||
|
@ -48,7 +48,7 @@ python3 roentgen.py element --node amenity=bench,material=wood \
|
|||
|| { echo "FAIL"; exit 1; }
|
||||
|
||||
echo "Test tile generation"
|
||||
python3 roentgen.py tile --coordinates 50.000,40.000 --cache test/data \
|
||||
python3 roentgen.py tile --coordinates 50.000,40.000 --cache tests/data \
|
||||
|| { echo "FAIL"; exit 1; }
|
||||
|
||||
exit 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue