diff --git a/README.md b/README.md index a3887fbcea..401ccd6414 100644 --- a/README.md +++ b/README.md @@ -571,9 +571,9 @@ affects the report output. This is a reserved feature name and any non-reporting based options chosen will not affect the output of Tarpaulin. For reference on available keys and their types refer to the CLI help text -at the start of the readme or `src/config/mod.rs` for the concrete types +at the start of the readme or [`src/config/mod.rs`](https://github.com/xd009642/tarpaulin/blob/develop/src/config/mod.rs) for the concrete types if anything is unclear. For arguments to be passed into the test binary that -follow `--` in Tarpaulin use `args` in the toml file. +follow `--` in Tarpaulin use `args` in the toml file. Find an example in the projects [`tarpaulin.toml](./tarpaulin.toml) file. Setting the field `config` will not affect the run as it won't be parsed for additional configuration. diff --git a/tarpaulin.toml b/tarpaulin.toml index f6d987290f..fc91b1a18b 100644 --- a/tarpaulin.toml +++ b/tarpaulin.toml @@ -1,4 +1,189 @@ [test_config] -engine = "Llvm" -follow-exec = true +# The name of the project or the configuration. +name = "tarpaulin" + +# Path to the project's cargo manifest. +# The manifest path is required for Tarpaulin to find the project. +manifest-path = "./Cargo.toml" + +# Optional path to a custom tarpaulin.toml config file. +# config = null + +# Path to the project's root directory. +# This is optional and can be used to override the default location. +# root = null + +# Flag to run tests with the ignored attribute. +# If true, ignored tests will be included in the coverage report. +run-ignored = false + +# Ignore panic macros in code during coverage analysis. +ignore-panics = false + +# Force a clean step before building the project. +# This will clean the target directory before running tests. +force-clean = false + +# Skip the clean step and proceed without cleaning the target directory. skip-clean = true + +# Enable verbose logging for user information during tests. +verbose = true + +# Enable debugging information for internal issues. +debug = false + +# Enable the event logger for trace dumps. +dump-traces = false + +# Count hits for coverage, useful for more detailed reporting. +count = true + +# Set the type of coverage to be run: +# - 'line' for line coverage (default) +# - 'branch' for branch coverage +line-coverage = true +branch-coverage = false + +# Directory to output coverage files and reports. +output-dir = "./coverage_output" + +# Optional key for a coveralls service or repository. +# coveralls = null + +# Specify the CI server tool for integration with coverage reports. +# Only valid if coveralls is set. +# ci-tool = null + +# Report URI to send results to a custom endpoint if provided. +# report-uri = null + +# Forward unexpected signals back to the tracee (useful for tests relying on signals). +forward-signals = false + +# Flag to disable linking with `-Clink-dead-code`. +no-dead-code = false + +# Include all available features in the build. +all-features = false + +# Exclude default features from the build. +no-default-features = false + +# Build all packages in the workspace. +workspace = false + +# Timeout duration for tests to finish. +# (in a format that human-time library can parse, e.g., "5m" for 5 minutes) +test-timeout = "10m" + +# Build in release mode for optimized builds. +release = false + +# Do not run the tests, only build them (for faster compilation). +no-run = false + +# Do not update the `Cargo.lock` file. +locked = false + +# Do not update the `Cargo.lock` or any caches. +frozen = false + +# Build for a specific target architecture or OS. +# target = null + +# Directory for storing generated build artifacts. +target-dir = "./target" + +# Run the tests without accessing the network (offline mode). +offline = false + +# Cargo subcommand to run; options are "test" or "build". +command = "test" + +# Types of tests to collect coverage for. For example: ["unit", "integration"] +run-types = ["unit"] + +# List of packages to include when building the target project. +packages = ["my_package"] + +# List of packages to exclude from testing. +exclude = [] + +# List of file paths to exclude from testing. +exclude-files = [] + +# Additional arguments to pass to the test executables. +args = [] + +# Features to include in the build, e.g., "feature1 feature2". +# features = null + +# List of unstable cargo features to use. +unstable-features = [] + +# Output files to generate as part of the test execution. +generate = [] + +# List of test names to run (corresponding to `cargo --test `). +test-names = [] + +# List of binary names to run (corresponding to `cargo --bin `). +bin-names = [] + +# List of example names to run (corresponding to `cargo --example `). +example-names = [] + +# List of bench names to run (corresponding to `cargo --bench `). +bench-names = [] + +# Flag to allow the process to stop immediately on a test failure. +no-fail-fast = false + +# Specify a custom profile to use when building. +# profile = null + +# Fail if coverage is below the specified threshold (e.g., 80.0). +# fail-under = null + +# Metadata generated from `cargo metadata` (this field is internal and usually empty). +# metadata = null + +# Flag to avoid passing `--cfg=tarpaulin` to the Rust compiler. +avoid-cfg-tarpaulin = false + +# Colouring of logs in the terminal output (e.g., "auto", "always", "never"). +color = "auto" + +# Follow traced executables down through function calls. +follow-exec = true + +# Number of jobs (threads) to use for building the tests. +# jobs = null + +# Allow the test suite to use implicit test threads if needed. +implicit-test-threads = true + +# Specify the engine to use for collecting coverage (default: "trace"). +engine = "Llvm" + +# Additional rust flags to be passed during the build process. +# rustflags = null + +# Include test functions in the coverage statistics. +include-tests = true + +# Delay after tests to collect instrumentation files (LLVM only). +# post-test-delay = 0 + +# Additional objects to be included in the coverage instrumentation. +objects = [] + +# Directory where profraw files are stored. +profraw-folder = "./target/profraw" + +# Fail immediately after a single test fails. +fail-immediately = false + +# Log to stderr instead of the default output. +stderr = false \ No newline at end of file