mirror of
https://github.com/sharkdp/bat.git
synced 2026-10-30 10:06:12 +00:00
When PAGER=most, don't print a warning to stderr, silently use less instead
This commit is contained in:
1 parent
552545fe5f
commit
22bdc7c20f
3 files changed
+9
-8
No files matched your search
@@ -423,8 +423,8 @@ fn pager_most() {
|
||||
.arg("test.txt")
|
||||
.assert()
|
||||
.success()
|
||||
.stderr(predicate::eq("\x1b[33m[bat warning]\x1b[0m: Ignoring PAGER=\"most\": Coloring not supported. Override with BAT_PAGER=\"most\" or --pager \"most\"\n").normalize())
|
||||
.stdout(predicate::eq("hello world\n").normalize());
|
||||
// TODO: How to ensure less is used?
|
||||
}
|
||||
|
||||
#[test]
|
||||
@@ -435,8 +435,8 @@ fn pager_most_with_arg() {
|
||||
.arg("test.txt")
|
||||
.assert()
|
||||
.success()
|
||||
.stderr(predicate::eq("\x1b[33m[bat warning]\x1b[0m: Ignoring PAGER=\"most -w\": Coloring not supported. Override with BAT_PAGER=\"most -w\" or --pager \"most -w\"\n").normalize())
|
||||
.stdout(predicate::eq("hello world\n").normalize());
|
||||
// TODO: How to ensure less is used?
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in new issue
Block a user