summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxegineering <me@xegineering.eu>2024-10-02 20:51:53 +0200
committerxegineering <me@xegineering.eu>2024-10-02 20:54:25 +0200
commitcdb89bfc9705bdee18a6893d1bb2678f6b8b7edd (patch)
tree3bc87dffdf27404c8c4068cf55d0df3225193caa
parent8db6c63f1bd3d4dc54dddbacf411ae6a9f33f6de (diff)
downloadsoundbox-go-cdb89bfc9705bdee18a6893d1bb2678f6b8b7edd.tar
soundbox-go-cdb89bfc9705bdee18a6893d1bb2678f6b8b7edd.tar.zst
soundbox-go-cdb89bfc9705bdee18a6893d1bb2678f6b8b7edd.zip
Add basic check.py
This script should be usable as a Git pre-commit hook to make sure every commit has a running test suite and is well formatted. This commit starts with running the test suite for the module.
-rwxr-xr-xcheck.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/check.py b/check.py
new file mode 100755
index 0000000..47819a1
--- /dev/null
+++ b/check.py
@@ -0,0 +1,17 @@
+#!/usr/bin/env python3
+
+
+import subprocess
+import pathlib
+
+
+def main() -> None:
+ subprocess.run(
+ ["go", "test", "-v"],
+ check=True,
+ cwd=pathlib.Path(__file__).parent,
+ )
+
+
+if __name__ == "__main__":
+ main()