Lines Matching +full:- +full:- +full:no +full:- +full:default +full:- +full:features
3 # Use of this source code is governed by a BSD-style license that can be
23 black = cmd("black").with_color_arg(always="--color", never="--no-color")
35 installed_toolchains = cmd("rustup target list --installed").lines()
56 return [python.with_cwd(TOOLS_ROOT).with_args("-m", file) for file in PYTHON_TESTS]
61 return [mypy("--pretty", file) for file in context.all_files]
67 "--check" if not context.fix else None,
74 if "blaze" in mdformat("--version").stdout():
80 "--wrap 100",
81 "--check" if not context.fix else "",
89 …long arguments: https://learn.microsoft.com/en-us/windows/win32/api/processthreadsapi/nf-processth…
92 .with_args("--check" if not context.fix else "")
98 "Runs cargo-doc and verifies that no warnings are emitted."
99 return cmd("./tools/cargo-doc").with_env("RUSTDOCFLAGS", "-D warnings").with_color_flag()
106 "--doc",
107 "--workspace",
108 "--features=all-x86_64",
113 "Runs cargo-doc and verifies that no warnings are emitted."
124 dut = "--dut=vm"
126 dut = "--dut=vm"
127 return cmd("./tools/run_tests --verbose --platform", platform, dut).with_color_flag()
138 return cmd("./tools/run_tests --verbose --platform", platform).with_color_flag()
146 platform: Platform, features: Optional[str] = None, no_default_features: bool = False
150 "./tools/run_tests --no-run --verbose --platform",
152 f"--features={features}" if features is not None else None,
153 "--no-default-features" if no_default_features else None,
156 check.__doc__ = f"Builds crosvm for {platform} with features {features}."
166 "./tools/clippy --platform",
168 "--fix" if context.fix else None,
184 "--fix" if can_fix and context.fix else None,
187 check.__name__ = name.replace("-", "_")
196 # Check names default to the function name minus the check_ prefix
253 check_crosvm_build(platform, features="default"),
262 check_crosvm_build(platform, features="", no_default_features=True),
267 # TODO: b/260607247 crosvm does not compile with no-default-features on mingw64
300 custom_check("check-copyright-header"),
313 custom_check("check-rust-features"),
317 custom_check("check-rust-lockfiles"),
321 custom_check("check-line-endings"),
324 custom_check("check-file-ends-with-newline"),
344 # Configures pre-defined groups of checks. Some are configured for CI builders and others
348 # The default group is run if no check or group is explicitly set
350 name="default",
351 doc="Checks run by default",
400 doc="Health checks to run by default",
429 doc=f"Checks run on the linux-{platform} builder",
435 # TODO: b/260607247 crosvm does not compile with no-default-features on mingw64
452 raise Exception(f"Group {group.name} includes non-existing item {check}.")
470 def get_check_names_in_group(group: Group) -> Generator[str, None, None]:
478 @argh.arg("--list-checks", default=False, help="List names of available checks and exit.")
479 @argh.arg("--fix", default=False, help="Asks checks to fix problems where possible.")
480 @argh.arg("--no-delta", default=False, help="Run on all files instead of just modified files.")
481 @argh.arg("--no-parallel", default=False, help="Do not run checks in parallel.")
484 help="List of checks or groups to run. Defaults to run the `default` group.",
497 checks_or_groups = ("default",)
507 raise Exception(f"No such check or group: {check_or_group}")
533 Basic usage, to run a default selection of checks:
539 ./tools/presubmit --fix