feat(profile): add lslocks
This commit is contained in:
parent
f516e1140a
commit
926a6fdcb9
2 changed files with 55 additions and 0 deletions
22
tests/integration/utils/lslocks.bats
Normal file
22
tests/integration/utils/lslocks.bats
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/env bats
|
||||
# apparmor.d - Full set of apparmor profiles
|
||||
# Copyright (C) 2024 Alexandre Pujol <alexandre@pujol.io>
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
|
||||
load ../common
|
||||
|
||||
@test "lslocks: List all local system locks" {
|
||||
sudo lslocks
|
||||
}
|
||||
|
||||
@test "lslocks: List locks producing a raw output (no columns), and without column headers" {
|
||||
sudo lslocks --raw --noheadings
|
||||
}
|
||||
|
||||
@test "lslocks: List locks by PID input" {
|
||||
sudo lslocks --pid "$(sudo lslocks --raw --noheadings --output PID | head -1)"
|
||||
}
|
||||
|
||||
@test "lslocks: List locks with JSON output to stdout" {
|
||||
lslocks --json
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue