pub struct Test { /* private fields */ }
Expand description
Test builder
Implementations§
Source§impl Test
impl Test
Sourcepub fn src_base(name: &str, src_base: impl AsRef<Path>) -> Self
pub fn src_base(name: &str, src_base: impl AsRef<Path>) -> Self
Test a library on all source files in a directory (similar to ui_test
).
Sourcepub fn example(name: &str, example: &str) -> Self
pub fn example(name: &str, example: &str) -> Self
Test a library on one example target (similar to ui_test_example
).
Sourcepub fn examples(name: &str) -> Self
pub fn examples(name: &str) -> Self
Test a library on all example targets (similar to ui_test_examples
).
Sourcepub fn rustc_flags(
&mut self,
rustc_flags: impl IntoIterator<Item = impl AsRef<str>>,
) -> &mut Self
pub fn rustc_flags( &mut self, rustc_flags: impl IntoIterator<Item = impl AsRef<str>>, ) -> &mut Self
Pass flags to the compiler when running the test.
Sourcepub fn dylint_toml(&mut self, dylint_toml: impl AsRef<str>) -> &mut Self
pub fn dylint_toml(&mut self, dylint_toml: impl AsRef<str>) -> &mut Self
Set the dylint.toml
file’s contents (for testing configurable libraries).
Auto Trait Implementations§
impl Freeze for Test
impl RefUnwindSafe for Test
impl Send for Test
impl Sync for Test
impl Unpin for Test
impl UnwindSafe for Test
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more