'User should be able to do a one click purchase of a program even if the ecommerce API throws an exception
during the calculation of program discounted price.'

@httpretty.activate
def test_fetching_program_discounted_price_api_exception_caught(self):

    self._prepare_program_for_discounted_price_calculation_endpoint()
    httpretty.register_uri(httpretty.GET, self.ECOMMERCE_CALCULATE_DISCOUNT_ENDPOINT, status=400, content_type='application/json')
    data = ProgramMarketingDataExtender(self.program, self.user).extend()
    self.assertEqual(data['skus'], [course['course_runs'][0]['seats'][0]['sku'] for course in self.program['courses']])
