diff options
author | Daniel Silverstone <dsilvers+gitlab@digital-scurf.org> | 2021-04-16 15:00:10 +0000 |
---|---|---|
committer | Daniel Silverstone <dsilvers+gitlab@digital-scurf.org> | 2021-04-16 15:00:10 +0000 |
commit | 164666a8640d7a42949817f3d79c1f34b9e2ec24 (patch) | |
tree | 59dd8f18b17d76287c68fa5d3a16bd368733ea0b | |
parent | 08740caf6595d3d69458d8196bd489440d508289 (diff) | |
parent | b2f4936aebc2e76f34ccb5c0e9691aa5c6c7b787 (diff) | |
download | subplot-164666a8640d7a42949817f3d79c1f34b9e2ec24.tar.gz |
Merge branch 'check-for-missing-tooling' into 'main'
build: check environment for tooling ./check needs, first thing
Closes #171
See merge request larswirzenius/subplot!148
-rwxr-xr-x | check | 26 |
1 files changed, 25 insertions, 1 deletions
@@ -237,6 +237,28 @@ def check_subplotlib(r): r.docgen(md, base + ".pdf", cwd=dirname) +def check_tooling(r): + """Check build environment for tooling the test suite needs""" + commands = [ + "bash", + "cargo", + "dot", + "pandoc", + "pandoc-citeproc", + "pdflatex", + "plantuml", + "rustc", + ] + for command in commands: + if not r.got_command(command): + sys.exit(f"can't find {command}, which is needed for test suite") + + if not r.got_command("daemonize") and not r.got_command("/usr/sbin/daemonize"): + sys.exit( + "can't find daemonize in PATH or in /usr/sbin, but it's needed for test suite" + ) + + def get_template(filename): prefix = "template: " with open(filename) as f: @@ -259,7 +281,7 @@ def parse_args(): "--strict", action="store_true", help="don't allow compiler warnings" ) - all_whats = ["python", "shell", "rust", "subplots", "subplotlib"] + all_whats = ["tooling", "python", "shell", "rust", "subplots", "subplotlib"] p.add_argument( "what", nargs="*", default=all_whats, help=f"what to test: {all_whats}" ) @@ -283,6 +305,8 @@ def main(): check_subplots(r) elif what == "subplotlib": check_subplotlib(r) + elif what == "tooling": + check_tooling(r) else: sys.exit(f"Unknown test {what}") |