-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathMakefile
58 lines (43 loc) · 1.74 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# some useful commands for developing
update-rest-api:
poetry run python dlt_init_openapi/utils/update_rest_api.py
dev:
poetry install --all-extras
# lint
lint: update-rest-api
rm -rf tests/_local
poetry run flake8 dlt_init_openapi tests
poetry run mypy dlt_init_openapi tests
poetry run black tests dlt_init_openapi --check
poetry run isort black tests dlt_init_openapi --check --diff
# format the whole project
format: update-rest-api
rm -rf tests/_local
poetry run isort black tests dlt_init_openapi
poetry run black tests dlt_init_openapi
# all tests excluding the checks on e2e tests
test: update-rest-api
poetry run python dlt_init_openapi/utils/update_rest_api.py
poetry run pytest tests --ignore=tests/e2e
# test without running all the specs through a source
test-fast: update-rest-api
poetry run pytest tests -m "not slow" --ignore=tests/e2e
test-slow: update-rest-api
poetry run pytest tests -m "slow" --ignore=tests/e2e
# dev helpers
create-pokemon-pipeline:
poetry run dlt-init-openapi pokemon --url https://raw.githubusercontent.com/cliffano/pokeapi-clients/ec9a2707ef2a85f41b747d8df013e272ef650ec5/specification/pokeapi.yml --no-interactive
create-pokemon-pipeline-interactive:
poetry run dlt-init-openapi pokemon --url https://raw.githubusercontent.com/cliffano/pokeapi-clients/ec9a2707ef2a85f41b747d8df013e272ef650ec5/specification/pokeapi.yml
# e2e test helpers
create-e2e-pokemon-pipeline:
poetry run dlt-init-openapi pokemon --path tests/cases/e2e_specs/pokeapi.yml --global-limit 2 --no-interactive
run-pokemon-pipeline:
cd pokemon_pipeline && poetry run python pokemon_pipeline.py
check-pokemon-pipeline:
poetry run pytest tests/e2e
build-library: dev
poetry version
poetry build
publish-library: build-library
poetry publish