public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
blob 37db17c39ce632f7c99cf652cbbece2d9e7421bb 1137 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
 
#!/usr/bin/env python3

import os
import sys


def check_avocado_version():
    minimum_version = 106.0

    def error_out():
        print(
            f"Avocado version {minimum_version} or later is required.\n"
            f"You may install it with: \n"
            f"   python3 -m pip install avocado-framework",
            file=sys.stderr,
        )
        sys.exit(1)

    try:
        from avocado import VERSION

        if (float(VERSION)) < minimum_version:
            error_out()
    except ImportError:
        error_out()


check_avocado_version()
from avocado.core.job import Job
from avocado.core.suite import TestSuite


def main():
    repo_root_path = os.path.abspath(
        os.path.dirname(os.path.dirname(os.path.dirname(__file__)))
    )
    config = {
        "resolver.references": [
            os.path.join(repo_root_path, "test", "avocado", "static_checkers.json")
        ],
        "runner.identifier_format": "{args[0]}",
    }
    suite = TestSuite.from_config(config, name="static_checkers")
    with Job(config, [suite]) as j:
        return j.run()


if __name__ == "__main__":
    sys.exit(main())

debug log:

solving 37db17c3 ...
found 37db17c3 in https://archives.passt.top/passt-dev/20240719065907.3539211-2-david@gibson.dropbear.id.au/ ||
	https://archives.passt.top/passt-dev/20240826020942.545155-2-david@gibson.dropbear.id.au/ ||
	https://archives.passt.top/passt-dev/20240805123701.1720730-4-david@gibson.dropbear.id.au/

applying [1/1] https://archives.passt.top/passt-dev/20240719065907.3539211-2-david@gibson.dropbear.id.au/
diff --git a/test/run_avocado b/test/run_avocado
new file mode 100755
index 00000000..37db17c3

Checking patch test/run_avocado...
Applied patch test/run_avocado cleanly.

skipping https://archives.passt.top/passt-dev/20240826020942.545155-2-david@gibson.dropbear.id.au/ for 37db17c3
skipping https://archives.passt.top/passt-dev/20240805123701.1720730-4-david@gibson.dropbear.id.au/ for 37db17c3
index at:
100755 37db17c39ce632f7c99cf652cbbece2d9e7421bb	test/run_avocado

Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).