1
0
mirror of https://github.com/sharkdp/bat.git synced 2025-09-02 03:12:25 +01:00

Move snapshot tests into separate module

This commit is contained in:
sharkdp
2018-10-07 12:20:48 +02:00
committed by David Peter
parent 6d1cc8c2c8
commit e09d7dabb8

View File

@@ -1,8 +1,9 @@
mod tester;
use tester::BatTester;
mod snapshot {
use tester::BatTester;
macro_rules! snapshot_tests {
macro_rules! snapshot_tests {
($($test_name: ident: $style: expr => [wrap: $wrap:expr, tabs: $tabs:expr],)*) => {
$(
#[test]
@@ -12,9 +13,9 @@ macro_rules! snapshot_tests {
}
)*
};
}
}
snapshot_tests! {
snapshot_tests! {
changes: "changes" => [wrap: false, tabs: 8],
grid: "grid" => [wrap: false, tabs: 8],
header: "header" => [wrap: false, tabs: 8],
@@ -38,4 +39,5 @@ snapshot_tests! {
tabs_passthrough: "full" => [wrap: false, tabs: 0],
tabs_4: "full" => [wrap: false, tabs: 4],
tabs_8: "full" => [wrap: false, tabs: 8],
}
}