on master help sign in
Add integration test for style rule
c1af6ffTom Milligan
tests/integration_tests.rs+20
@@ -680,6 +680,26 @@ fn header_padding() {
680 .stderr("");
680 .stderr("");
681}
681}
682
682
683+#[test]
684+fn header_padding_rule() {
685+ bat()
686+ .arg("--decorations=always")
687+ .arg("--style=header,rule")
688+ .arg("--terminal-width=80")
689+ .arg("test.txt")
690+ .arg("single-line.txt")
691+ .assert()
692+ .stdout(
693+ "File: test.txt
694+hello world
695+────────────────────────────────────────────────────────────────────────────────
696+File: single-line.txt
697+Single Line
698+",
699+ )
700+ .stderr("");
701+}
702+
683#[cfg(target_os = "linux")]
703#[cfg(target_os = "linux")]
684#[test]
704#[test]
685fn file_with_invalid_utf8_filename() {
705fn file_with_invalid_utf8_filename() {