def METHOD_NAME(cls):
    factory = AppFactory(domain=cls.domain.name, name="API App", build_version='2.11.0')
    module1, form1 = factory.new_basic_module('open_case', 'house')
    form1.source = XFormBuilder().new_question("name", "name").form.tostring()
    factory.form_opens_case(form1)
    module2, form2 = factory.new_basic_module('update_case', 'person')
    form2.source = XFormBuilder().new_question("name", "name").form.tostring()
    factory.form_requires_case(form2, case_type='house')
    factory.form_opens_case(form2, case_type="person", is_subcase=True)
    app = factory.app
    app.save()
    return app