'Verify that a profile\'s image obeys parental controls.'

def test_profile_image(self):

    self.profile.profile_image_uploaded_at = datetime.datetime.now()
    self.profile.save()
    self.assertFalse(self.profile.has_profile_image)
    current_year = datetime.datetime.now().year
    self.set_year_of_birth((current_year - 20))
    self.profile.profile_image_uploaded_at = datetime.datetime.now()
    self.profile.save()
    self.assertTrue(self.profile.has_profile_image)
    self.set_year_of_birth((current_year - 10))
    self.profile.save()
    self.assertFalse(self.profile.has_profile_image)
