'Tests that a generated purchase report CSV is as we expect'

def test_refund_report_purchased_csv(self):

    report = initialize_report('refund_report', (self.now - self.FIVE_MINS), (self.now + self.FIVE_MINS))
    csv_file = StringIO.StringIO()
    report.write_csv(csv_file)
    csv = csv_file.getvalue()
    csv_file.close()
    self.assertEqual(csv.replace('\r\n', '\n').strip(), self.CORRECT_REFUND_REPORT_CSV.strip())
