Skip to content

Commit b9d2ba0

Browse files
committed
fix some tests
1 parent 4351907 commit b9d2ba0

File tree

4 files changed

+3
-20
lines changed

4 files changed

+3
-20
lines changed

pkg/cli/predict.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,6 @@ func parseInputFlags(inputs []string, schema *openapi3.T) (predict.Inputs, error
277277
if strings.HasPrefix(value, `"`) && strings.HasSuffix(value, `"`) {
278278
value = value[1 : len(value)-1]
279279
}
280-
281280
currVal, present := keyVals[name]
282281
if present {
283282
keyVals[name] = append(currVal, value)

pkg/predict/input.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import (
1212
)
1313

1414
type Input struct {
15-
String *string
16-
File *string
15+
String *string
16+
File *string
1717
StringList *[]string
1818
}
1919

python/tests/server/fixtures/input_unsupported_type.py

Lines changed: 0 additions & 11 deletions
This file was deleted.

python/tests/server/test_http_input.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def test_file_input_with_http_url(client, httpserver, match):
103103

104104
@uses_predictor("input_path_2")
105105
def test_file_input_with_http_url_error(client, httpserver, match):
106-
httpserver.expect_request("/foo.txt").respond_with_data("haha", status = 404)
106+
httpserver.expect_request("/foo.txt").respond_with_data("haha", status=404)
107107
resp = client.post(
108108
"/predictions",
109109
json={"input": {"path": httpserver.url_for("/foo.txt")}},
@@ -216,8 +216,3 @@ def test_choices_int(client):
216216
def test_untyped_inputs():
217217
with pytest.raises(TypeError):
218218
make_client("input_untyped")
219-
220-
221-
def test_input_with_unsupported_type():
222-
with pytest.raises(TypeError):
223-
make_client("input_unsupported_type")

0 commit comments

Comments
 (0)