1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 03:27:44 +00:00

tests/refactor ~ use is_ci() for CI host platform testing

This commit is contained in:
Roy Ivy III 2020-06-13 21:51:59 -05:00
parent 407d455b12
commit d144182add
4 changed files with 9 additions and 24 deletions

View file

@ -13,10 +13,7 @@ fn test_normal() {
for (key, value) in env::vars() {
println!("{}: {}", key, value);
}
if env::var("USER").is_ok()
&& env::var("USER").unwrap() == "runner"
&& result.stderr.contains("error: no login name")
{
if is_ci() && result.stderr.contains("error: no login name") {
// In the CI, some server are failing to return logname.
// As seems to be a configuration issue, ignoring it
return;