@@ -866,22 +866,22 @@ def testCheckAndParseInputConfigKey(self):
866866 self .assertEqual (input_name , None )
867867 self .assertEqual (field_name , "label_map_path" )
868868
869- with self .assertRaisesRegexp (ValueError ,
869+ with self .assertRaisesRegex (ValueError ,
870870 "Invalid key format when overriding configs." ):
871871 config_util .check_and_parse_input_config_key (
872872 configs , "train_input_config:shuffle" )
873873
874- with self .assertRaisesRegexp (
874+ with self .assertRaisesRegex (
875875 ValueError , "Invalid key_name when overriding input config." ):
876876 config_util .check_and_parse_input_config_key (
877877 configs , "invalid_key_name:train_name:shuffle" )
878878
879- with self .assertRaisesRegexp (
879+ with self .assertRaisesRegex (
880880 ValueError , "Invalid input_name when overriding input config." ):
881881 config_util .check_and_parse_input_config_key (
882882 configs , "eval_input_configs:unknown_eval_name:shuffle" )
883883
884- with self .assertRaisesRegexp (
884+ with self .assertRaisesRegex (
885885 ValueError , "Invalid field_name when overriding input config." ):
886886 config_util .check_and_parse_input_config_key (
887887 configs , "eval_input_configs:eval_2:unknown_field_name" )
@@ -919,7 +919,7 @@ def testUpdateInputReaderConfigErrors(self):
919919 _write_config (pipeline_config , pipeline_config_path )
920920 configs = config_util .get_configs_from_pipeline_file (pipeline_config_path )
921921
922- with self .assertRaisesRegexp (ValueError ,
922+ with self .assertRaisesRegex (ValueError ,
923923 "Duplicate input name found when overriding." ):
924924 config_util .update_input_reader_config (
925925 configs ,
@@ -928,7 +928,7 @@ def testUpdateInputReaderConfigErrors(self):
928928 field_name = "shuffle" ,
929929 value = False )
930930
931- with self .assertRaisesRegexp (
931+ with self .assertRaisesRegex (
932932 ValueError , "Input name name_not_exist not found when overriding." ):
933933 config_util .update_input_reader_config (
934934 configs ,
@@ -937,7 +937,7 @@ def testUpdateInputReaderConfigErrors(self):
937937 field_name = "shuffle" ,
938938 value = False )
939939
940- with self .assertRaisesRegexp (ValueError ,
940+ with self .assertRaisesRegex (ValueError ,
941941 "Unknown input config overriding." ):
942942 config_util .update_input_reader_config (
943943 configs ,
0 commit comments