[Patchew-devel] [PATCH 1/4] manage.py: Run tests/ if no test specified

Fam Zheng posted 4 patches 7 years, 6 months ago
[Patchew-devel] [PATCH 1/4] manage.py: Run tests/ if no test specified
Posted by Fam Zheng 7 years, 6 months ago
Just to make ./manage.py slightly more usable.

Signed-off-by: Fam Zheng <famz@redhat.com>
---
 manage.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/manage.py b/manage.py
index 4d598f9..a1533b8 100755
--- a/manage.py
+++ b/manage.py
@@ -16,4 +16,7 @@ if __name__ == "__main__":
 
     from django.core.management import execute_from_command_line
 
-    execute_from_command_line(sys.argv)
+    args = list(sys.argv)
+    if len(args) == 2 and args[1] == "test":
+        args.append("tests")
+    execute_from_command_line(args)
-- 
2.17.1

_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel