summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMartin Nordholts <enselic@gmail.com>2021-01-07 12:56:47 +0100
committerMartin Nordholts <enselic@gmail.com>2021-01-07 12:58:26 +0100
commitda1016662588cae98aeb96b2ec570b14f02f9c62 (patch)
tree0fb64d8ab5c0427251527ff6b300f98955211bf6 /tests
parent46487b201ff0f4cdcbfdea9d328cbac6d29a22d1 (diff)
parentb6b7262962ab67d34ad98788aff6ed78f1e763e3 (diff)
Merge remote-tracking branch 'origin/master' into fix-1063
Diffstat (limited to 'tests')
-rw-r--r--tests/integration_tests.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/integration_tests.rs b/tests/integration_tests.rs
index c79f4d90..49aea8b9 100644
--- a/tests/integration_tests.rs
+++ b/tests/integration_tests.rs
@@ -7,10 +7,16 @@ use std::fs::File;
use std::path::{Path, PathBuf};
use std::process::{Command, Stdio};
use std::str::from_utf8;
+
+#[cfg(unix)]
use std::time::Duration;
const EXAMPLES_DIR: &str = "tests/examples";
+
+#[cfg(unix)]
const SAFE_CHILD_PROCESS_CREATION_TIME: Duration = Duration::from_millis(100);
+
+#[cfg(unix)]
const CHILD_WAIT_TIMEOUT: Duration = Duration::from_secs(15);
fn bat_raw_command() -> Command {
@@ -670,6 +676,17 @@ fn alias_pager_disable_long_overrides_short() {
}
#[test]
+fn pager_failed_to_parse() {
+ bat()
+ .env("BAT_PAGER", "mismatched-quotes 'a")
+ .arg("--paging=always")
+ .arg("test.txt")
+ .assert()
+ .failure()
+ .stderr(predicate::str::contains("Could not parse pager command"));
+}
+
+#[test]
fn config_location_test() {
bat_with_config()
.env("BAT_CONFIG_PATH", "bat.conf")