2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-08-22 10:07:12 +00:00

6 Commits

Author SHA1 Message Date
Christian Boltz
66cb0af47c
*TestParseInvalid: move tests not matching regex into tests array 2025-06-29 18:26:10 +02:00
Christian Boltz
2a37040415
Introduce AATest.parseInvalidRule()
... and change all *TestParseInvalid classes to use it, instead of
having (nearly) the same function in every test-*.py.

While at it, enable the tests for abi and include rules.
2025-06-29 17:35:48 +02:00
Christian Boltz
a13d8cfffb
utils: move tests for invalid priority to test-*
... instead of having them in test-modifiers.py for all rule types

Also add a few additional tests while on it.
2025-06-24 18:11:14 +02:00
John Johansen
c0fcd1698b utils: add support for priority rule prefix
Add basic support for the priority rules prefix. This patch does not
allow the utils to set or suggest priorities. It allows parsing and
retaining of the priority prefix if it already exists on rules and
checking if it's in the supported range.

Signed-off-by: Georgia Garcia <georgia.garcia@canonical.com>
Signed-off-by: John Johansen <john.johansen@canonical.com>
2025-05-05 14:54:22 -03:00
Georgia Garcia
cec9ae6dff utils: fix coding style to match PEP8
Annotate exceptions with '  # noqa: ERROR'

Signed-off-by: Georgia Garcia <georgia.garcia@canonical.com>
2024-05-20 13:56:37 -03:00
Christian Boltz
e361644d5a
Utils: add support for the 'all,' rule 2023-09-10 18:07:41 +02:00