mirror of
https://github.com/safing/portmaster
synced 2025-09-02 02:29:12 +00:00
25 lines
404 B
Go
25 lines
404 B
Go
package matcher
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/Safing/portmaster/process"
|
|
)
|
|
|
|
func TestGetIdentifierLinux(t *testing.T) {
|
|
p := &process.Process{
|
|
Path: "/usr/lib/firefox/firefox",
|
|
}
|
|
|
|
if GetIdentificationPath(p) != "lin:lib/firefox/firefox" {
|
|
t.Fatal("mismatch!")
|
|
}
|
|
|
|
p = &process.Process{
|
|
Path: "/opt/start",
|
|
}
|
|
|
|
if GetIdentificationPath(p) != "lin:/opt/start" {
|
|
t.Fatal("mismatch!")
|
|
}
|
|
}
|