aboutsummaryrefslogtreecommitdiff
path: root/tools/interface_generator/private/defs.bzl
blob: 080f19a2b945676c12c56f7045649f417bc2f65a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
load("@pip//:requirements.bzl", "requirement")

def py_pytest(name, srcs, deps = [], **kwargs):
    native.py_test(
        name = name,
        srcs = ["//private:pytest_wrapper.py"],
        main = "//private:pytest_wrapper.py",
        data = srcs,
        args = [
            "--black",
            "--pylint",
            #"--mypy",
        ] + ["$(location :%s)" % x for x in srcs],
        deps = [
            requirement("pytest"),
            requirement("pytest-black"),
            requirement("pytest-pylint"),
            requirement("pytest-mypy"),
        ] + deps,
        **kwargs
    )