Implement ctrlaltdel (#31)

* Implement ctrlaltdel

* Add tests for `ctrlaltdel`

* Bless the unit tests on unsupported platforms
This commit is contained in:
sisungo
2024-05-12 19:37:17 +08:00
committed by GitHub
parent 572f84b1f3
commit c9ee7d6447
8 changed files with 191 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
// This file is part of the uutils util-linux package.
//
// For the full copyright and license information, please view the LICENSE
// file that was distributed with this source code.
// spell-checker:ignore (words) symdir somefakedir
#[cfg(target_os = "linux")]
use crate::common::util::TestScenario;
#[test]
#[cfg(target_os = "linux")]
fn test_invalid_arg() {
new_ucmd!().arg("--definitely-invalid").fails().code_is(1);
}

View File

@@ -12,3 +12,7 @@ mod test_lscpu;
#[cfg(feature = "mountpoint")]
#[path = "by-util/test_mountpoint.rs"]
mod test_mountpoint;
#[cfg(feature = "ctrlaltdel")]
#[path = "by-util/test_ctrlaltdel.rs"]
mod test_ctrlaltdel;