pub struct TestBodies { /* private fields */ }Expand description
Test bodies of at least min_lines start collapsed on both sides, paired
or not, so a diff reads as the code under test first. A whole test
module, such as a Rust #[cfg(test)] mod tests, collapses as one fold
labelled “test module”; the header stays visible and the fold expands
like any other. A test body is linked to its docstring, which collapses
with it.
Trait Implementations§
Source§impl Plugin for TestBodies
impl Plugin for TestBodies
Source§type Options = Options
type Options = Options
The plugin’s options, deserialized from its bundled or external config
entry: a JSON object, validated against the options schema in
plugin.toml and filled with its defaults.Source§fn new(options: Options) -> Result<Self>
fn new(options: Options) -> Result<Self>
Make the plugin from its options. An error, like options that do not
deserialize, is a setup error naming the plugin.
Source§fn queries(&self) -> Result<Vec<QuerySource>>
fn queries(&self) -> Result<Vec<QuerySource>>
Named query text, collected once during setup and compiled by diffr.
Source§fn classify(&self, _file: &FileEntry) -> Result<Vec<String>>
fn classify(&self, _file: &FileEntry) -> Result<Vec<String>>
Tags to add to the file’s manifest entry before it is diffed. A
plugin that does not classify returns none.
Auto Trait Implementations§
impl Freeze for TestBodies
impl RefUnwindSafe for TestBodies
impl Send for TestBodies
impl Sync for TestBodies
impl Unpin for TestBodies
impl UnsafeUnpin for TestBodies
impl UnwindSafe for TestBodies
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