mirror of
https://github.com/ovh/debian-cis.git
synced 2025-06-22 02:33:42 +02:00
FIX(13.15): fix code that did not show duplicated group
Add tests Apply shellcheck recommendations
This commit is contained in:
@ -6,5 +6,20 @@ test_audit() {
|
||||
# shellcheck disable=2154
|
||||
run blank /opt/debian-cis/bin/hardening/"${script}".sh --audit-all
|
||||
|
||||
# TODO fill comprehensive tests
|
||||
|
||||
groupadd -f -g 120 grouptest
|
||||
groupadd -fo -g 120 grouptest2
|
||||
|
||||
describe Duplicated groups
|
||||
register_test retvalshouldbe 1
|
||||
run duplicated /opt/debian-cis/bin/hardening/"${script}".sh --audit-all
|
||||
|
||||
# Cleanup
|
||||
groupdel grouptest
|
||||
groupdel grouptest2
|
||||
|
||||
describe Compliant state
|
||||
register_test retvalshouldbe 0
|
||||
run resolved /opt/debian-cis/bin/hardening/"${script}".sh --audit-all
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user