Struct predicates::path::BinaryFilePredicate [−][src]
pub struct BinaryFilePredicate { /* fields omitted */ }
Predicate that compares file matches
Implementations
impl BinaryFilePredicate
[src]
impl BinaryFilePredicate
[src]pub fn utf8(self) -> Option<StrFilePredicate>
[src]
Creates a new Predicate
that ensures complete equality
Examples
use std::path::Path; use predicates::prelude::*; let predicate_file = predicate::path::eq_file(Path::new("Cargo.toml")).utf8().unwrap(); assert_eq!(true, predicate_file.eval(Path::new("Cargo.toml"))); assert_eq!(false, predicate_file.eval(Path::new("Cargo.lock"))); assert_eq!(false, predicate_file.eval(Path::new("src"))); assert_eq!(false, predicate_file.eval("Not a real Cargo.toml file content"));
Trait Implementations
impl Clone for BinaryFilePredicate
[src]
impl Clone for BinaryFilePredicate
[src]fn clone(&self) -> BinaryFilePredicate
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Eq for BinaryFilePredicate
[src]
impl Eq for BinaryFilePredicate
[src]impl PartialEq<BinaryFilePredicate> for BinaryFilePredicate
[src]
impl PartialEq<BinaryFilePredicate> for BinaryFilePredicate
[src]fn eq(&self, other: &BinaryFilePredicate) -> bool
[src]
fn ne(&self, other: &BinaryFilePredicate) -> bool
[src]
impl Predicate<Path> for BinaryFilePredicate
[src]
impl Predicate<Path> for BinaryFilePredicate
[src]impl StructuralEq for BinaryFilePredicate
[src]
impl StructuralEq for BinaryFilePredicate
[src]Auto Trait Implementations
impl RefUnwindSafe for BinaryFilePredicate
impl RefUnwindSafe for BinaryFilePredicate
impl Send for BinaryFilePredicate
impl Send for BinaryFilePredicate
impl Sync for BinaryFilePredicate
impl Sync for BinaryFilePredicate
impl Unpin for BinaryFilePredicate
impl Unpin for BinaryFilePredicate
impl UnwindSafe for BinaryFilePredicate
impl UnwindSafe for BinaryFilePredicate
Blanket Implementations
impl<P, Item> PredicateBooleanExt<Item> for P where
Item: ?Sized,
P: Predicate<Item>,
[src]
impl<P, Item> PredicateBooleanExt<Item> for P where
Item: ?Sized,
P: Predicate<Item>,
[src]fn and<B>(self, other: B) -> AndPredicate<Self, B, Item> where
B: Predicate<Item>,
Self: Sized,
[src]
B: Predicate<Item>,
Self: Sized,
fn or<B>(self, other: B) -> OrPredicate<Self, B, Item> where
B: Predicate<Item>,
Self: Sized,
[src]
B: Predicate<Item>,
Self: Sized,
fn not(self) -> NotPredicate<Self, Item> where
Self: Sized,
[src]
Self: Sized,
impl<P, Item> PredicateNameExt<Item> for P where
Item: ?Sized,
P: Predicate<Item>,
[src]
impl<P, Item> PredicateNameExt<Item> for P where
Item: ?Sized,
P: Predicate<Item>,
[src]fn name(self, name: &'static str) -> NamePredicate<Self, Item> where
Self: Sized,
[src]
Self: Sized,