Skip to content

Commit 6c21d58

Browse files
committed
tests: add external_libstdbuf cfg alias
1 parent bf797ef commit 6c21d58

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

build.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ use cfg_aliases::cfg_aliases;
1414

1515
pub fn main() {
1616
cfg_aliases! {
17+
external_libstdbuf: { feature = "feat_external_libstdbuf" },
1718
selinux: { all(feature = "feat_selinux", any(target_os = "android", target_os = "linux")) },
1819
}
1920

tests/by-util/test_stdbuf.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ fn invalid_input() {
1515
new_ucmd!().arg("-/").fails_with_code(125);
1616
}
1717

18-
#[cfg(not(feature = "feat_external_libstdbuf"))]
18+
#[cfg(not(external_libstdbuf))]
1919
#[test]
2020
fn test_permission() {
2121
new_ucmd!()
@@ -27,7 +27,7 @@ fn test_permission() {
2727

2828
// LD_DEBUG is not available on macOS, OpenBSD, Android, or musl
2929
#[cfg(all(
30-
feature = "feat_external_libstdbuf",
30+
external_libstdbuf,
3131
not(target_os = "windows"),
3232
not(target_os = "openbsd"),
3333
not(target_os = "macos"),
@@ -121,7 +121,7 @@ fn test_stdbuf_search_order_exe_dir_first() {
121121
);
122122
}
123123

124-
#[cfg(not(feature = "feat_external_libstdbuf"))]
124+
#[cfg(not(external_libstdbuf))]
125125
#[test]
126126
fn test_no_such() {
127127
new_ucmd!()

0 commit comments

Comments
 (0)