Add integration tests

This commit is contained in:
Dash Peters 2020-06-30 12:41:50 -07:00
parent 2575aae945
commit bfac6fd85c
1 changed files with 23 additions and 0 deletions

View File

@ -405,6 +405,29 @@ fn pager_disable() {
.stdout(predicate::eq("hello world\n").normalize());
}
#[test]
fn alias_pager_disable() {
bat()
.env("PAGER", "echo other-pager")
.arg("-P")
.arg("test.txt")
.assert()
.success()
.stdout(predicate::eq("hello world\n").normalize());
}
#[test]
fn alias_pager_disable_long_overrides_short() {
bat()
.env("PAGER", "echo pager-output")
.arg("-P")
.arg("--paging=always")
.arg("test.txt")
.assert()
.success()
.stdout(predicate::eq("pager-output\n").normalize());
}
#[test]
fn config_location_test() {
bat_with_config()