Пример #1
0
 def get_incomplete_requirements_fields(self, instance):
     """Returns a list of all the requirement fields that are incomplete."""
     return get_incomplete_fields(
         instance,
         LARGE_CAPITAL_REQUIREMENTS_FIELDS,
         LargeCapitalInvestorProfile,
     )
Пример #2
0
 def get_incomplete_location_fields(self, instance):
     """Returns a list of all the location fields that are incomplete."""
     return get_incomplete_fields(
         instance,
         LARGE_CAPITAL_LOCATION_FIELDS,
         LargeCapitalInvestorProfile,
     )
Пример #3
0
 def get_incomplete_details_fields(self, instance):
     """Returns a list of all the detail fields that are incomplete."""
     return get_incomplete_fields(
         instance,
         LARGE_CAPITAL_DETAILS_FIELDS,
         LargeCapitalInvestorProfile,
     )
Пример #4
0
def test_incomplete_fields():
    """Tests incomplete fields on an investor profile are returned."""
    instance = LargeCapitalInvestorProfileFactory.build()
    result = get_incomplete_fields(
        instance,
        ['investor_company', 'investor_description'],
        LargeCapitalInvestorProfile,
    )
    assert result == ['investor_description']