Skip to content

Commit b4f6e9e

Browse files
committed
fix windows nightly
Fixes #5519
1 parent 455e559 commit b4f6e9e

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

sstable/reader_iter_treesteps_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
package sstable
66

77
import (
8+
"strings"
89
"testing"
910

1011
"github.com/cockroachdb/datadriven"
@@ -71,7 +72,7 @@ func runIterTreeStepsCmd(t *testing.T, r *Reader, td *datadriven.TestData) strin
7172
iter, err := r.NewIter(NoTransforms, nil /* lower */, nil /* upper */, TableBlobContext{})
7273
require.NoError(t, err)
7374

74-
rec := treesteps.StartRecording(iter, td.Pos)
75+
rec := treesteps.StartRecording(iter, strings.ReplaceAll(td.Pos, "\\", "/"))
7576
runIterCmd(td, iter, false)
7677

7778
steps := rec.Finish()

treesteps_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
package pebble
88

99
import (
10+
"strings"
1011
"testing"
1112

1213
"github.com/cockroachdb/datadriven"
@@ -105,5 +106,5 @@ func treeStepsStartRecording(
105106
if depth != 0 {
106107
opts = append(opts, treesteps.MaxTreeDepth(depth))
107108
}
108-
return treesteps.StartRecording(node, td.Pos, opts...)
109+
return treesteps.StartRecording(node, strings.ReplaceAll(td.Pos, "\\", "/"), opts...)
109110
}

vfs/disk_health_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import (
88
"io"
99
"math"
1010
"os"
11+
"path/filepath"
1112
"runtime"
1213
"sync"
1314
"sync/atomic"
@@ -649,7 +650,7 @@ func TestDiskSlowInfo(t *testing.T) {
649650
// Essential information should be present
650651
require.Contains(t, result, "disk slowness detected")
651652
require.Contains(t, result, "write")
652-
require.Contains(t, result, "/some/really/deep/path/to/wal/000123.log")
653+
require.Contains(t, result, filepath.FromSlash(info.Path))
653654
require.Contains(t, result, "(123 bytes)")
654655
require.Contains(t, result, "5.0s")
655656

0 commit comments

Comments
 (0)