gradema.test._rust¶
Module Contents¶
Classes¶
- class gradema.test._rust.RustProgram(main_location: str | os.PathLike[str] | pathlib.Path, binary_location: str | os.PathLike[str] | pathlib.Path)¶
- create_compile_step() gradema.test.Test¶
- create_stdio_test(test_identifier: str, args: Sequence[gradema.test.argument.Argument], input_file: pathlib.Path | None, goal_file: pathlib.Path, stdout_as_output: bool) gradema.test.Test¶
- create_traditional_stdio_test(test_identifier: str, input_file: pathlib.Path, goal_file: pathlib.Path) gradema.test.Test¶
- create_traditional_arg_test(test_identifier: str, args: Sequence[gradema.test.argument.Argument], goal_file: pathlib.Path) gradema.test.Test¶
- create_format_check() gradema.test.Test¶
Creates a rustfmt check.
Note that the resulting command will be something like
rustfmt --check src/main.rs. Even though this only includes the main file, all files referenced by main will also be format checked – it’s not necessary to list all the files here! https://github.com/rust-lang/rustfmt/issues/2426- Returns:
A test that completes successfully when there are no formatting errors
- create_cargo_command(arguments: list[str]) gradema.test.Test¶