feat(aa-log): improve logs cleaning and varible resolution.
This commit is contained in:
parent
83bc7d3ade
commit
00d6a664eb
5 changed files with 44 additions and 35 deletions
|
|
@ -30,7 +30,7 @@ func TestGetJournalctlLogs(t *testing.T) {
|
|||
"apparmor": "ALLOWED",
|
||||
"label": "gsd-xsettings",
|
||||
"operation": "dbus_method_call",
|
||||
"name": ":*",
|
||||
"name": "@{busname}",
|
||||
"mask": "receive",
|
||||
"bus": "session",
|
||||
"path": "/org/gtk/Settings",
|
||||
|
|
@ -50,8 +50,8 @@ func TestGetJournalctlLogs(t *testing.T) {
|
|||
for _, tt := range tests {
|
||||
t.Run(tt.name, func(t *testing.T) {
|
||||
reader, _ := GetJournalctlLogs(tt.path, tt.useFile)
|
||||
if got := NewApparmorLogs(reader, tt.name); !reflect.DeepEqual(got, tt.want) {
|
||||
t.Errorf("NewApparmorLogs() = %v, want %v", got, tt.want)
|
||||
if got := New(reader, tt.name); !reflect.DeepEqual(got, tt.want) {
|
||||
t.Errorf("New() = %v, want %v", got, tt.want)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue