Skip to content

Commit

Permalink
correction for linux
Browse files Browse the repository at this point in the history
  • Loading branch information
bgn42 committed Sep 9, 2024
1 parent 15524cc commit 107fbf1
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions cmd/cli_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import (
"io"
"os"
"path/filepath"
"runtime"
"strings"
"testing"
)
Expand Down Expand Up @@ -89,7 +88,7 @@ func TestCli(t *testing.T) {

expected := `<index>
<vendor>testing_vendor_index</vendor>
<url>file:///XX/test-continue-despite-errors.xml</url>
<url>file://XX/test-continue-despite-errors.xml</url>
<>
<pindex>
<pdsc vendor="TheVendor" url="test/" name="ThePack2" version="1.1.0" timestamp=""></pdsc>
Expand All @@ -100,9 +99,6 @@ func TestCli(t *testing.T) {
</index>`
wd, _ := os.Getwd()
wd = filepath.ToSlash(wd)
if runtime.GOOS == "windows" {
expected = strings.Replace(expected, "///XX", "//XX", -1)
}
expected = strings.Replace(expected, "XX", wd, -1)
s := string(out)
sa, se, _ := strings.Cut(s, "timestamp") // cut out time, cannot compare
Expand Down

0 comments on commit 107fbf1

Please sign in to comment.