From c1af6ff2e6f7c596b381a70da8d37c7a28f764f0 Mon Sep 17 00:00:00 2001 From: Tom Milligan Date: Thu, 8 Oct 2020 09:59:14 +0100 Subject: [PATCH] Add integration test for style rule --- tests/integration_tests.rs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/tests/integration_tests.rs b/tests/integration_tests.rs index 9dfa8067..a55d081d 100644 --- a/tests/integration_tests.rs +++ b/tests/integration_tests.rs @@ -680,6 +680,26 @@ fn header_padding() { .stderr(""); } +#[test] +fn header_padding_rule() { + bat() + .arg("--decorations=always") + .arg("--style=header,rule") + .arg("--terminal-width=80") + .arg("test.txt") + .arg("single-line.txt") + .assert() + .stdout( + "File: test.txt +hello world +──────────────────────────────────────────────────────────────────────────────── +File: single-line.txt +Single Line +", + ) + .stderr(""); +} + #[cfg(target_os = "linux")] #[test] fn file_with_invalid_utf8_filename() {