2022-08-18 10:20:31 +02:00
|
|
|
#[cfg(feature = "git")]
|
2018-10-10 22:56:56 +02:00
|
|
|
mod tester;
|
|
|
|
|
|
|
|
macro_rules! snapshot_tests {
|
2018-10-19 21:10:32 +02:00
|
|
|
($($test_name: ident: $style: expr,)*) => {
|
2018-10-10 22:56:56 +02:00
|
|
|
$(
|
|
|
|
#[test]
|
2022-08-18 10:20:31 +02:00
|
|
|
#[cfg(feature = "git")]
|
2018-10-10 22:56:56 +02:00
|
|
|
fn $test_name() {
|
2022-08-18 10:20:31 +02:00
|
|
|
let bat_tester = tester::BatTester::default();
|
2018-10-19 21:10:32 +02:00
|
|
|
bat_tester.test_snapshot(stringify!($test_name), $style);
|
2018-10-10 22:56:56 +02:00
|
|
|
}
|
|
|
|
)*
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
snapshot_tests! {
|
2018-10-19 21:10:32 +02:00
|
|
|
changes: "changes",
|
|
|
|
grid: "grid",
|
|
|
|
header: "header",
|
|
|
|
numbers: "numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
rule: "rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
changes_grid: "changes,grid",
|
|
|
|
changes_header: "changes,header",
|
|
|
|
changes_numbers: "changes,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
changes_rule: "changes,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
grid_header: "grid,header",
|
|
|
|
grid_numbers: "grid,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
grid_rule: "grid,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
header_numbers: "header,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
header_rule: "header,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
changes_grid_header: "changes,grid,header",
|
|
|
|
changes_grid_numbers: "changes,grid,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
changes_grid_rule: "changes,grid,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
changes_header_numbers: "changes,header,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
changes_header_rule: "changes,header,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
grid_header_numbers: "grid,header,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
grid_header_rule: "grid,header,rule",
|
|
|
|
header_numbers_rule: "header,numbers,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
changes_grid_header_numbers: "changes,grid,header,numbers",
|
2020-10-06 17:57:47 +02:00
|
|
|
changes_grid_header_rule: "changes,grid,header,rule",
|
|
|
|
changes_grid_header_numbers_rule: "changes,grid,header,numbers,rule",
|
2018-10-19 21:10:32 +02:00
|
|
|
full: "full",
|
|
|
|
plain: "plain",
|
2018-10-10 22:56:56 +02:00
|
|
|
}
|