@@ -337,7 +337,6 @@ async def test_use_concatenate_iterator_output(client_mode):
337337 "items" : {"type" : "string" },
338338 "x-cog-array-type" : "iterator" ,
339339 "x-cog-array-display" : "concatenate" ,
340- "title" : "Output" ,
341340 }
342341 }
343342 }
@@ -348,7 +347,7 @@ async def test_use_concatenate_iterator_output(client_mode):
348347 )
349348 mock_prediction_endpoints (
350349 predictions = [
351- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
350+ create_mock_prediction (),
352351 create_mock_prediction (
353352 {"status" : "succeeded" , "output" : ["Hello" , " " , "world" , "!" ]}
354353 ),
@@ -424,7 +423,6 @@ async def test_use_list_of_strings_output(client_mode):
424423 "Output" : {
425424 "type" : "array" ,
426425 "items" : {"type" : "string" },
427- "title" : "Output" ,
428426 }
429427 }
430428 }
@@ -435,7 +433,7 @@ async def test_use_list_of_strings_output(client_mode):
435433 )
436434 mock_prediction_endpoints (
437435 predictions = [
438- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
436+ create_mock_prediction (),
439437 create_mock_prediction (
440438 {"status" : "succeeded" , "output" : ["hello" , "world" , "test" ]}
441439 ),
@@ -467,7 +465,6 @@ async def test_use_iterator_of_strings_output(client_mode):
467465 "type" : "array" ,
468466 "items" : {"type" : "string" },
469467 "x-cog-array-type" : "iterator" ,
470- "title" : "Output" ,
471468 }
472469 }
473470 }
@@ -478,7 +475,7 @@ async def test_use_iterator_of_strings_output(client_mode):
478475 )
479476 mock_prediction_endpoints (
480477 predictions = [
481- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
478+ create_mock_prediction (),
482479 create_mock_prediction (
483480 {"status" : "succeeded" , "output" : ["hello" , "world" , "test" ]}
484481 ),
@@ -514,7 +511,6 @@ async def test_use_path_output(client_mode):
514511 "Output" : {
515512 "type" : "string" ,
516513 "format" : "uri" ,
517- "title" : "Output" ,
518514 }
519515 }
520516 }
@@ -525,7 +521,7 @@ async def test_use_path_output(client_mode):
525521 )
526522 mock_prediction_endpoints (
527523 predictions = [
528- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
524+ create_mock_prediction (),
529525 create_mock_prediction (
530526 {"status" : "succeeded" , "output" : "https://example.com/output.jpg" }
531527 ),
@@ -562,7 +558,6 @@ async def test_use_list_of_paths_output(client_mode):
562558 "Output" : {
563559 "type" : "array" ,
564560 "items" : {"type" : "string" , "format" : "uri" },
565- "title" : "Output" ,
566561 }
567562 }
568563 }
@@ -573,7 +568,7 @@ async def test_use_list_of_paths_output(client_mode):
573568 )
574569 mock_prediction_endpoints (
575570 predictions = [
576- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
571+ create_mock_prediction (),
577572 create_mock_prediction (
578573 {
579574 "status" : "succeeded" ,
@@ -623,7 +618,6 @@ async def test_use_iterator_of_paths_output(client_mode):
623618 "type" : "array" ,
624619 "items" : {"type" : "string" , "format" : "uri" },
625620 "x-cog-array-type" : "iterator" ,
626- "title" : "Output" ,
627621 }
628622 }
629623 }
@@ -634,7 +628,7 @@ async def test_use_iterator_of_paths_output(client_mode):
634628 )
635629 mock_prediction_endpoints (
636630 predictions = [
637- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
631+ create_mock_prediction (),
638632 create_mock_prediction (
639633 {
640634 "status" : "succeeded" ,
@@ -810,17 +804,7 @@ def capture_request(request):
810804@respx .mock
811805async def test_use_function_logs_method (client_mode ):
812806 mock_model_endpoints ()
813- mock_prediction_endpoints (
814- predictions = [
815- create_mock_prediction (
816- {
817- "status" : "processing" ,
818- "output" : None ,
819- "logs" : "Starting prediction..." ,
820- },
821- ),
822- ]
823- )
807+ mock_prediction_endpoints (predictions = [create_mock_prediction ()])
824808
825809 # Call use and then create method
826810 hotdog_detector = replicate .use ("acme/hotdog-detector" )
@@ -882,15 +866,13 @@ async def test_use_object_output_with_file_properties(client_mode):
882866 "Output" : {
883867 "type" : "object" ,
884868 "properties" : {
885- "text" : {"type" : "string" , "title" : "Text" },
869+ "text" : {"type" : "string" },
886870 "image" : {
887871 "type" : "string" ,
888872 "format" : "uri" ,
889- "title" : "Image" ,
890873 },
891- "count" : {"type" : "integer" , "title" : "Count" },
874+ "count" : {"type" : "integer" },
892875 },
893- "title" : "Output" ,
894876 }
895877 }
896878 }
@@ -901,7 +883,7 @@ async def test_use_object_output_with_file_properties(client_mode):
901883 )
902884 mock_prediction_endpoints (
903885 predictions = [
904- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
886+ create_mock_prediction (),
905887 create_mock_prediction (
906888 {
907889 "status" : "succeeded" ,
@@ -948,17 +930,15 @@ async def test_use_object_output_with_file_list_property(client_mode):
948930 "Output" : {
949931 "type" : "object" ,
950932 "properties" : {
951- "text" : {"type" : "string" , "title" : "Text" },
933+ "text" : {"type" : "string" },
952934 "images" : {
953935 "type" : "array" ,
954936 "items" : {
955937 "type" : "string" ,
956938 "format" : "uri" ,
957939 },
958- "title" : "Images" ,
959940 },
960941 },
961- "title" : "Output" ,
962942 }
963943 }
964944 }
@@ -969,7 +949,7 @@ async def test_use_object_output_with_file_list_property(client_mode):
969949 )
970950 mock_prediction_endpoints (
971951 predictions = [
972- create_mock_prediction ({ "status" : "processing" , "output" : None } ),
952+ create_mock_prediction (),
973953 create_mock_prediction (
974954 {
975955 "status" : "succeeded" ,
0 commit comments