Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(144)

Unified Diff: client/archiver/directory_test.go

Issue 2535803004: isolate: give up and die on file unavailability (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: client/archiver/directory_test.go
diff --git a/client/archiver/directory_test.go b/client/archiver/directory_test.go
index 7aa067c4a6fe799241a1c1453caa8cc8a63d70c5..337310a5aaf0182b77789208ab4382a54eab57b4 100644
--- a/client/archiver/directory_test.go
+++ b/client/archiver/directory_test.go
@@ -7,7 +7,6 @@ package archiver
import (
"encoding/json"
"errors"
- "fmt"
"io/ioutil"
"net/http/httptest"
"os"
@@ -23,28 +22,6 @@ import (
"github.com/maruel/ut"
)
-func TestWalkInexistent(t *testing.T) {
- ch := make(chan *walkItem)
- var wg sync.WaitGroup
- wg.Add(1)
- go func() {
- defer wg.Done()
- defer close(ch)
- walk("inexistent_directory", nil, ch)
- }()
- item := <-ch
- osErr := "lstat inexistent_directory: no such file or directory"
- if common.IsWindows() {
- osErr = "GetFileAttributesEx inexistent_directory: The system cannot find the file specified."
- }
- err := fmt.Errorf("walk(inexistent_directory): %s", osErr)
- ut.AssertEqual(t, &walkItem{err: err}, item)
- item, ok := <-ch
- ut.AssertEqual(t, (*walkItem)(nil), item)
- ut.AssertEqual(t, false, ok)
- wg.Wait()
-}
-
func TestWalkBadRegexp(t *testing.T) {
ch := make(chan *walkItem)
var wg sync.WaitGroup

Powered by Google App Engine
This is Rietveld 408576698