Add csv attachment; fix controller tests.