mirror of
https://github.com/restic/rest-server.git
synced 2026-09-26 05:51:24 -07:00
Fix TestListWithUnexpectedFiles test
The test should test both API versions.
This commit is contained in:
+3
-1
@@ -422,7 +422,9 @@ func TestListWithUnexpectedFiles(t *testing.T) {
|
|||||||
|
|
||||||
for i := 1; i <= 2; i++ {
|
for i := 1; i <= 2; i++ {
|
||||||
req := newRequest(t, "GET", "/data/", nil)
|
req := newRequest(t, "GET", "/data/", nil)
|
||||||
req.Header.Set("Accept", "application/vnd.x.restic.rest.v2")
|
if i == 2 {
|
||||||
|
req.Header.Set("Accept", "application/vnd.x.restic.rest.v2")
|
||||||
|
}
|
||||||
|
|
||||||
checkRequest(t, mux.ServeHTTP, req,
|
checkRequest(t, mux.ServeHTTP, req,
|
||||||
[]wantFunc{wantCode(http.StatusOK)})
|
[]wantFunc{wantCode(http.StatusOK)})
|
||||||
|
|||||||
Reference in New Issue
Block a user