[][src]Struct cargo_tarpaulin::config::Config

pub struct Config {
    pub manifest: PathBuf,
    pub root: Option<String>,
    pub run_types: Vec<RunType>,
    pub run_ignored: bool,
    pub ignore_tests: bool,
    pub ignore_panics: bool,
    pub force_clean: bool,
    pub verbose: bool,
    pub debug: bool,
    pub count: bool,
    pub line_coverage: bool,
    pub branch_coverage: bool,
    pub generate: Vec<OutputFile>,
    pub output_directory: PathBuf,
    pub coveralls: Option<String>,
    pub ci_tool: Option<CiService>,
    pub report_uri: Option<String>,
    pub forward_signals: bool,
    pub all_features: bool,
    pub no_default_features: bool,
    pub features: Vec<String>,
    pub unstable_features: Vec<String>,
    pub all: bool,
    pub packages: Vec<String>,
    pub exclude: Vec<String>,
    pub varargs: Vec<String>,
    pub test_timeout: Duration,
    pub release: bool,
    pub no_run: bool,
    pub locked: bool,
    pub frozen: bool,
    pub target_dir: Option<PathBuf>,
    pub offline: bool,
    // some fields omitted
}

Specifies the current configuration tarpaulin is using.

Fields

manifest: PathBuf

Path to the projects cargo manifest

root: Option<String>

Path to the projects cargo manifest

run_types: Vec<RunType>

Types of tests for tarpaulin to collect coverage on

run_ignored: bool

Flag to also run tests with the ignored attribute

ignore_tests: bool

Flag to ignore test functions in coverage statistics

ignore_panics: bool

Ignore panic macros in code.

force_clean: bool

Flag to add a clean step when preparing the target project

verbose: bool

Verbose flag for printing information to the user

debug: bool

Debug flag for printing internal debugging information to the user

count: bool

Flag to count hits in coverage

line_coverage: bool

Flag specifying to run line coverage (default)

branch_coverage: bool

Flag specifying to run branch coverage

generate: Vec<OutputFile>

Output files to generate

output_directory: PathBuf

Directory to write output files

coveralls: Option<String>

Key relating to coveralls service or repo

ci_tool: Option<CiService>

Enum representing CI tool used.

report_uri: Option<String>

Only valid if coveralls option is set. If coveralls option is set, as well as report_uri, then the report will be sent to this endpoint instead.

forward_signals: bool

Forward unexpected signals back to the tracee. Used for tests which rely on signals to work.

all_features: bool

Include all available features in target build

no_default_features: bool

Do not include default features in target build

features: Vec<String>

Features to include in the target project build

unstable_features: Vec<String>

Unstable cargo features to use

all: bool

Build all packages in the workspace

packages: Vec<String>

Packages to include when building the target project

exclude: Vec<String>

Packages to exclude from testing

varargs: Vec<String>

Varargs to be forwarded to the test executables.

test_timeout: Duration

Duration to wait before a timeout occurs

release: bool

Build in release mode

no_run: bool

Build the tests only don't run coverage

locked: bool

Don't update Cargo.lock.

frozen: bool

Don't update Cargo.lock or any caches.

target_dir: Option<PathBuf>

Directory for generated artifacts

offline: bool

Run tarpaulin on project without accessing the network

Methods

impl Config[src]

pub fn is_coveralls(&self) -> bool[src]

pub fn exclude_path(&self, path: &Path) -> bool[src]

pub fn get_base_dir(&self) -> PathBuf[src]

returns the relative path from the base_dir uses root if set, else env::current_dir()

pub fn strip_base_dir(&self, path: &Path) -> PathBuf[src]

returns the relative path from the base_dir

pub fn is_default_output_dir(&self) -> bool[src]

Trait Implementations

impl Debug for Config[src]

impl Default for Config[src]

impl<'a> From<&'a ArgMatches<'a>> for Config[src]

Auto Trait Implementations

impl !RefUnwindSafe for Config

impl Send for Config

impl Sync for Config

impl Unpin for Config

impl UnwindSafe for Config

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,