def METHOD_NAME(self, to_delete):
    with TemporaryDirectory() as d:
        self.create_fake_directory(d)
        os.remove(os.path.join(d, to_delete))
        with self.assertRaises(OasisException):
            create_analysis_settings_json(d)