def test_with_bad_app(self):
        """Testing RenameModel with application not in signature"""
        mutation = RenameModel('TestModel', 'DestModel',
                               db_table='tests_destmodel')

        message = (
            'Cannot rename the model "badapp.TestModel". The application '
            'could not be found in the signature.'
        )

        with self.assertRaisesMessage(SimulationFailure, message):
            mutation.run_simulation(app_label='badapp',
                                    project_sig=ProjectSignature(),
                                    database_state=None)
    def test_with_bad_model(self):
        """Testing RenameModel with model not in signature"""
        mutation = RenameModel('TestModel', 'DestModel',
                               db_table='tests_destmodel')

        project_sig = ProjectSignature()
        project_sig.add_app_sig(AppSignature(app_id='tests'))

        message = (
            'Cannot rename the model "tests.TestModel". The model could '
            'not be found in the signature.'
        )

        with self.assertRaisesMessage(SimulationFailure, message):
            mutation.run_simulation(app_label='tests',
                                    project_sig=project_sig,
                                    database_state=None)