@@ -881,7 +881,7 @@ def test_get_custom_type(self):
881881 cs = interpreter .get_custom_type ()
882882 assert cs .struct_int == expected_cs .struct_int
883883 assert cs .struct_double == expected_cs .struct_double
884- assert type (cs ) == type (expected_cs )
884+ assert isinstance (cs , type (expected_cs ) )
885885 self ._assert_call (library_func , response_object ).assert_called_once_with (vi = GRPC_SESSION_OBJECT_FOR_TEST )
886886
887887 def test_set_custom_type_array (self ):
@@ -906,7 +906,7 @@ def test_get_custom_type_array(self):
906906 for actual , expected in zip (cs_test , cs ):
907907 assert actual .struct_int == expected .struct_int
908908 assert actual .struct_double == expected .struct_double
909- assert type (actual ) == type (expected )
909+ assert isinstance (actual , type (expected ) )
910910 self ._assert_call (library_func , response_object ).assert_called_once_with (
911911 vi = GRPC_SESSION_OBJECT_FOR_TEST , number_of_elements = len (cs )
912912 )
@@ -928,9 +928,9 @@ def test_get_custom_type_typedef(self):
928928 assert csnt_test .struct_custom_struct .struct_double == csnt .struct_custom_struct .struct_double
929929 assert csnt_test .struct_custom_struct_typedef .struct_int == csnt .struct_custom_struct_typedef .struct_int
930930 assert csnt_test .struct_custom_struct_typedef .struct_double == csnt .struct_custom_struct_typedef .struct_double
931- assert type (csnt_test .struct_custom_struct ) == type (csnt .struct_custom_struct ) # noqa: E721
932- assert type (csnt_test .struct_custom_struct_typedef ) == type (csnt .struct_custom_struct_typedef ) # noqa: E721
933- assert type (csnt_test ) == type (csnt )
931+ assert isinstance (csnt_test .struct_custom_struct , type (csnt .struct_custom_struct ))
932+ assert isinstance (csnt_test .struct_custom_struct_typedef , type (csnt .struct_custom_struct_typedef ))
933+ assert isinstance (csnt_test , type (csnt ) )
934934 request_object = self ._assert_call (library_func , response_object )
935935 request_object .assert_called_once ()
936936 call = request_object .call_args_list [0 ]
@@ -943,9 +943,9 @@ def test_get_custom_type_typedef(self):
943943 assert sent_csnt .struct_custom_struct .struct_double == grpc_csnt .struct_custom_struct .struct_double
944944 assert sent_csnt .struct_custom_struct_typedef .struct_int == grpc_csnt .struct_custom_struct_typedef .struct_int
945945 assert sent_csnt .struct_custom_struct_typedef .struct_double == grpc_csnt .struct_custom_struct_typedef .struct_double
946- assert type (sent_csnt .struct_custom_struct ) == type (grpc_csnt .struct_custom_struct ) # noqa: E721
947- assert type (sent_csnt .struct_custom_struct_typedef ) == type (grpc_csnt .struct_custom_struct_typedef ) # noqa: E721
948- assert type (sent_csnt ) == type (grpc_csnt )
946+ assert isinstance (sent_csnt .struct_custom_struct , type (grpc_csnt .struct_custom_struct ))
947+ assert isinstance (sent_csnt .struct_custom_struct_typedef , type (grpc_csnt .struct_custom_struct_typedef ))
948+ assert isinstance (sent_csnt , type (grpc_csnt ) )
949949
950950 def test_get_cal_date_time (self ):
951951 library_func = 'GetCalDateAndTime'
0 commit comments