Package the self-test script as an entrypoint
authorJeremy Stanley <fungi@yuggoth.org>
Mon, 20 Feb 2017 21:42:08 +0000 (21:42 +0000)
committerJeremy Stanley <fungi@yuggoth.org>
Mon, 20 Feb 2017 21:42:08 +0000 (21:42 +0000)
Move the self-test script into the Python package and define an
entrypoint for it in setup.cfg so a `mudpy_selftest` executable will
be installed.

.gitignore
mudpy/tests/selftest.py [moved from bin/test with 100% similarity, mode: 0644]
setup.cfg

index e833e8d..8f15c08 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (c) 2014-2016 Jeremy Stanley <fungi@yuggoth.org>. Permission
+# Copyright (c) 2014-2017 Jeremy Stanley <fungi@yuggoth.org>. Permission
 # to use, copy, modify, and distribute this software is granted under
 # terms provided in the LICENSE file distributed with this software.
 
@@ -8,5 +8,6 @@
 capture_*.log
 data/
 mudpy/__pycache__/
+mudpy/tests/__pycache__/
 test_config.yaml
 var/
old mode 100755 (executable)
new mode 100644 (file)
similarity index 100%
rename from bin/test
rename to mudpy/tests/selftest.py
index d87ca9b..6a177bc 100644 (file)
--- a/setup.cfg
+++ b/setup.cfg
@@ -1,4 +1,4 @@
-# Copyright (c) 2016 Jeremy Stanley <fungi@yuggoth.org>. Permission
+# Copyright (c) 2016-2017 Jeremy Stanley <fungi@yuggoth.org>. Permission
 # to use, copy, modify, and distribute this software is granted under
 # terms provided in the LICENSE file distributed with this software.
 
@@ -36,3 +36,4 @@ packages =
 [entry_points]
 console_scripts =
     mudpy = mudpy.daemon:main
+    mudpy_selftest = mudpy.tests.selftest:main