def test_message_appears_when_token_expires(self): request = self.create_and_return_http_request() profile_adder = ProfileAdder(request, test_data="notempty", token_timeout=0) profile_adder.request_profile() response = profile_adder.add_profile() self.assertContains(response, "Authorization Token Expired", 2)
def test_message_appears_when_token_expires(self): request = self.create_and_return_http_request() profile_adder = ProfileAdder(request, test_data="notempty", token_timeout=0) profile_adder.get_authorization() response = profile_adder.add_profile() self.assertContains(response, "Authorization Token Expired", 2)
def authorized_add(request, test_data=None): profile_adder = ProfileAdder(request, test_data) return profile_adder.add_profile()
def add_linked_in_profile(request, test_data=None): profile_adder = ProfileAdder(request, test_data) return profile_adder.get_authorization()