Skip to content

Commit

Permalink
TMP: Debug
Browse files Browse the repository at this point in the history
  • Loading branch information
fmeum committed Jun 25, 2024
1 parent ac73db1 commit 4ac1eaa
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions go/runfiles/manifest.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ func (f ManifestFile) parse() (manifest, error) {
s := bufio.NewScanner(r)
m := manifest{make(map[string]string), nil}
for s.Scan() {
fmt.Printf("s.Text(): %s\n", s.Text())
fields := strings.SplitN(s.Text(), " ", 2)
if len(fields) != 2 || fields[0] == "" {
return manifest{}, fmt.Errorf("runfiles: bad manifest line %q in file %s", s.Text(), f)
Expand Down
8 changes: 8 additions & 0 deletions tests/runfiles/testfs/testfs.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,14 @@ func testFS(fsys fs.FS, expected ...string) error {
if len(t.errText) == 0 {
return nil
}
var list []string
for k := range found {
if k != "." {
list = append(list, k)
}
}
sort.Strings(list)
t.errorf("found files:\n%s", strings.Join(list, "\n"))
return errors.New("TestFS found errors:\n" + string(t.errText))
}

Expand Down

0 comments on commit 4ac1eaa

Please sign in to comment.