def METHOD_NAME(self):
    lines = ['a', 'b', 'c']
    dir = self.mkdtemp()
    foo = os.path.join(dir, 'foo')
    write_file(foo, lines)
    content = [line.strip() for line in open(foo).readlines()]
    self.assertEqual(content, lines)