From b5b86d8eff147bcdf4ccd56348b6a4d9b92d3984 Mon Sep 17 00:00:00 2001 From: Richard Terry Date: Sat, 21 Sep 2024 10:41:54 +0100 Subject: [PATCH] Move examples/scale.py into examples/scale/ It has a lot of extra files, so moving it for clarity --- .gitignore | 5 ++++- examples/{ => scale}/scale.py | 0 examples/{ => scale}/static/info.svg | 0 examples/{ => scale}/templates/scale/countlog_list.html | 0 examples/{ => scale}/templates/scale/index.html | 0 examples/static/.gitkeep | 0 requirements.txt | 5 ++++- tests/test_convert.py | 2 +- tests/test_run_check.py | 2 +- tests/test_run_runserver.py | 2 +- 10 files changed, 11 insertions(+), 5 deletions(-) rename examples/{ => scale}/scale.py (100%) rename examples/{ => scale}/static/info.svg (100%) rename examples/{ => scale}/templates/scale/countlog_list.html (100%) rename examples/{ => scale}/templates/scale/index.html (100%) create mode 100644 examples/static/.gitkeep diff --git a/.gitignore b/.gitignore index e45f62f..38f63cc 100644 --- a/.gitignore +++ b/.gitignore @@ -22,7 +22,10 @@ Vagrantfile examples/*.sqlite3 examples/*migrations* examples/media -examples/static-collected +examples/scale/*.sqlite3 +examples/scale/*migrations* +examples/scale/media +examples/scale/static-collected # OS-specific .DS_Store diff --git a/examples/scale.py b/examples/scale/scale.py similarity index 100% rename from examples/scale.py rename to examples/scale/scale.py diff --git a/examples/static/info.svg b/examples/scale/static/info.svg similarity index 100% rename from examples/static/info.svg rename to examples/scale/static/info.svg diff --git a/examples/templates/scale/countlog_list.html b/examples/scale/templates/scale/countlog_list.html similarity index 100% rename from examples/templates/scale/countlog_list.html rename to examples/scale/templates/scale/countlog_list.html diff --git a/examples/templates/scale/index.html b/examples/scale/templates/scale/index.html similarity index 100% rename from examples/templates/scale/index.html rename to examples/scale/templates/scale/index.html diff --git a/examples/static/.gitkeep b/examples/static/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/requirements.txt b/requirements.txt index 1dd1229..59bb885 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,6 +2,9 @@ pip-tools black click +gunicorn isort django>=3.2.0 -django-ninja \ No newline at end of file +django-ninja +uvicorn +whitenoise diff --git a/tests/test_convert.py b/tests/test_convert.py index ec945b1..fe47239 100644 --- a/tests/test_convert.py +++ b/tests/test_convert.py @@ -3,7 +3,7 @@ from .utils import cmd, converted_process, runserver TEST_APP = "scale" -TEST_SCRIPT = f"examples/{TEST_APP}.py" +TEST_SCRIPT = f"examples/scale/{TEST_APP}.py" TEST_BIND = "127.0.0.1:8042" diff --git a/tests/test_run_check.py b/tests/test_run_check.py index 40e25be..8794f94 100644 --- a/tests/test_run_check.py +++ b/tests/test_run_check.py @@ -22,6 +22,6 @@ def test_run_check__counter_module(): def test_run_check__scale(): - result = cmd("manage", "examples/scale.py", "check") + result = cmd("manage", "examples/scale/scale.py", "check") assert result.stderr.strip() == "" assert result.stdout.strip() == "System check identified no issues (0 silenced)." diff --git a/tests/test_run_runserver.py b/tests/test_run_runserver.py index 4542a4a..2be3187 100644 --- a/tests/test_run_runserver.py +++ b/tests/test_run_runserver.py @@ -3,7 +3,7 @@ from .utils import cmd, nanodjango_process, runserver TEST_APP = "scale" -TEST_SCRIPT = f"examples/{TEST_APP}.py" +TEST_SCRIPT = f"examples/scale/{TEST_APP}.py" TEST_BIND = "127.0.0.1:8042"