1
0
Fork 0

test: remove obsolete match test

timestamps
dump_stack() 2023-05-18 21:40:22 +00:00
parent 120fcdc56b
commit 9c237b52db
Signed by: dump_stack
GPG Key ID: BE44DA8C062D87DC
1 changed files with 0 additions and 35 deletions

View File

@ -1,44 +1,9 @@
package debian
import (
"os"
"testing"
"code.dumpstack.io/tools/out-of-tree/config"
"code.dumpstack.io/tools/out-of-tree/distro"
"code.dumpstack.io/tools/out-of-tree/fs"
)
func TestMatch(t *testing.T) {
if os.Getenv("CI") != "" {
t.Skip("skip testing in CI")
}
t.Log("tested with cache by default")
tmp, err := fs.TempDir()
if err != nil {
return
}
defer os.RemoveAll(tmp)
config.Directory = tmp
km := config.Target{
Distro: distro.Distro{Release: "7"},
Kernel: config.Kernel{Regex: "3.2.0-4"},
}
pkgs, err := Match(km)
if err != nil {
t.Fatal(err)
}
if len(pkgs) == 0 {
t.Fatal("no packages")
}
}
func TestKernelRelease(t *testing.T) {
type testcase struct {
Deb string