build: exex directive: sort & cleanup generated rules.

This commit is contained in:
Alexandre Pujol 2024-03-22 20:56:04 +00:00
parent 73fe7a7475
commit d5470b8404
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
2 changed files with 9 additions and 9 deletions

View file

@ -28,9 +28,8 @@ func TestExec_Apply(t *testing.T) {
Raw: " #aa:exec DiscoverNotifier",
},
profile: ` #aa:exec DiscoverNotifier`,
want: ` @{lib}/DiscoverNotifier Px,
@{lib}/@{multiarch}/{,libexec/}DiscoverNotifier Px,
`,
want: ` @{lib}/@{multiarch}/{,libexec/}DiscoverNotifier Px,
@{lib}/DiscoverNotifier Px,`,
},
{
name: "exec-unconfined",
@ -43,8 +42,7 @@ func TestExec_Apply(t *testing.T) {
},
profile: ` #aa:exec U polkit-agent-helper`,
want: ` @{lib}/polkit-[0-9]/polkit-agent-helper-[0-9] Ux,
@{lib}/polkit-agent-helper-[0-9] Ux,
`,
@{lib}/polkit-agent-helper-[0-9] Ux,`,
},
}
for _, tt := range tests {