diff options
author | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2021-09-05 20:57:28 -0500 |
---|---|---|
committer | flu0r1ne <flu0r1ne@flu0r1ne.net> | 2021-09-05 20:57:28 -0500 |
commit | 087c51bed9da75f5585d176a7b14396cd70f2638 (patch) | |
tree | aaaf4a0de37eee63d8ec37f30dfa37cf61d2cf8f | |
parent | a4c190fb594f44da2849ec02c36117f35516c07d (diff) | |
download | deb-planr-087c51bed9da75f5585d176a7b14396cd70f2638.tar.xz deb-planr-087c51bed9da75f5585d176a7b14396cd70f2638.zip |
Temp unit test fix
-rw-r--r-- | debian/patches/fix-unit-tests | 13 | ||||
-rw-r--r-- | debian/patches/golang-1.3-compat-readdir | 4 | ||||
-rw-r--r-- | debian/patches/golang-1.3-compat-remove-prefix-logging | 8 | ||||
-rw-r--r-- | debian/patches/series | 1 |
4 files changed, 20 insertions, 6 deletions
diff --git a/debian/patches/fix-unit-tests b/debian/patches/fix-unit-tests new file mode 100644 index 0000000..5e914d2 --- /dev/null +++ b/debian/patches/fix-unit-tests @@ -0,0 +1,13 @@ +Index: planr/fs_test.go +=================================================================== +--- planr.orig/fs_test.go ++++ planr/fs_test.go +@@ -15,7 +15,7 @@ func TestCname(t *testing.T) { + } + + for _, vec := range v { +- got := cname(ROOT, vec.path) ++ got := Cname(ROOT, vec.path) + + if vec.cname != got { + t.Fatalf("Cname(%s) = %s, wanted %s", vec.path, got, vec.cname) diff --git a/debian/patches/golang-1.3-compat-readdir b/debian/patches/golang-1.3-compat-readdir index b9e5c6d..3c429a9 100644 --- a/debian/patches/golang-1.3-compat-readdir +++ b/debian/patches/golang-1.3-compat-readdir @@ -2,7 +2,7 @@ Index: planr/fs.go =================================================================== --- planr.orig/fs.go +++ planr/fs.go -@@ -224,7 +224,7 @@ func collectFromDir( +@@ -116,7 +116,7 @@ func collectFromDir( // Read the entries in this directory for { @@ -11,7 +11,7 @@ Index: planr/fs.go if err == io.EOF { break } else if err != nil { -@@ -233,8 +233,8 @@ func collectFromDir( +@@ -125,8 +125,8 @@ func collectFromDir( for _, ent := range dirs { diff --git a/debian/patches/golang-1.3-compat-remove-prefix-logging b/debian/patches/golang-1.3-compat-remove-prefix-logging index 08a1a9e..072be5d 100644 --- a/debian/patches/golang-1.3-compat-remove-prefix-logging +++ b/debian/patches/golang-1.3-compat-remove-prefix-logging @@ -2,13 +2,13 @@ Index: planr/cmd/planr/main.go =================================================================== --- planr.orig/cmd/planr/main.go +++ planr/cmd/planr/main.go -@@ -28,8 +28,7 @@ func dieUsage() { - - func main() { +@@ -73,8 +73,7 @@ func main() { + defer pprof.StopCPUProfile() + } - log.SetFlags(log.Llongfile | log.Lmsgprefix) - log.SetPrefix("planr: ") + log.SetFlags(log.Llongfile) - if len(os.Args) < 2 { + if flag.NArg() < 1 { dieUsage() diff --git a/debian/patches/series b/debian/patches/series index a80079f..8aa0b3d 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,2 +1,3 @@ golang-1.3-compat-readdir golang-1.3-compat-remove-prefix-logging +fix-unit-tests |