Skip tests properly (#31308)
* Skip tests properly * [test_all] * Add 'reason' as kwarg for skipTest * [test_all] Fix up * [test_all]
This commit is contained in:
@@ -947,7 +947,7 @@ class ProphetNetModelTest(ModelTesterMixin, GenerationTesterMixin, PipelineTeste
|
||||
config_and_inputs = self.model_tester.prepare_config_and_inputs()
|
||||
self.model_tester.check_prepare_lm_labels_via_shift_left(*config_and_inputs)
|
||||
|
||||
@unittest.skip("Flaky test with no simple resolution. TODO Fix me @patrickvonplaten")
|
||||
@unittest.skip(reason="Flaky test with no simple resolution. TODO Fix me @patrickvonplaten")
|
||||
def test_decoder_model_generate(self):
|
||||
config_and_inputs = self.model_tester.prepare_config_and_inputs()
|
||||
self.model_tester.create_and_check_generate_with_past_key_value_states(*config_and_inputs)
|
||||
@@ -1112,8 +1112,8 @@ class ProphetNetModelTest(ModelTesterMixin, GenerationTesterMixin, PipelineTeste
|
||||
self.assertIsNotNone(encoder_hidden_states.grad)
|
||||
self.assertIsNotNone(encoder_attentions.grad)
|
||||
|
||||
@unittest.skip(reason="Generating with head_masking has not been implemented for ProphetNet models yet.")
|
||||
def test_generate_with_head_masking(self):
|
||||
"""Generating with head_masking has not been implemented for ProphetNet models yet."""
|
||||
pass
|
||||
|
||||
|
||||
@@ -1141,8 +1141,8 @@ class ProphetNetStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMix
|
||||
config_and_inputs = self.model_tester.prepare_config_and_inputs()
|
||||
self.model_tester.create_and_check_decoder_model_attention_mask_past(*config_and_inputs)
|
||||
|
||||
@unittest.skip(reason="Decoder cannot keep gradients")
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user