[go: up one dir, main page]

expectorate 2.0.0

Library for comparing output to file contents with simple updating
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Copyright 2020 Oxide Computer Company

use expectorate::assert_contents;

#[test]
fn good() {
    let actual = include_str!("data_a.txt");
    assert_contents!("tests/data_a.txt", actual);
}

#[test]
#[should_panic]
fn bad() {
    let actual = include_str!("data_a.txt");
    assert_contents!("tests/data_b.txt", actual);
}