test(bigquery): address flaky error probing test
Context:  Looks like error mapping for excessively sized requests is
getting remapped to a more appropriate error code.  Change expectations
so we allow either HTTP 400 or 413 errors.
Fixes:
Fixes:
Fixes:
@@ -1249,8 +1249,8 @@ func TestIntegration_InsertErrors(t *testing.T) {
if !ok {
t.Errorf("wanted googleapi.Error, got: %v", err)
}
- if e.Code != http.StatusBadRequest {
- t.Errorf("Wanted HTTP 400, got %d", e.Code)
+ if e.Code != http.StatusBadRequest && e.Code != http.StatusRequestEntityTooLarge {
+ t.Errorf("Wanted HTTP 400 or 413, got %d", e.Code)
}
}
