`self.assertEquals(len(changes['modify']), 0)` and `self.assertEquals(len(changes['delete']), 0)` appear twice.

Instead of `self.assertEquals(changes['add'][0], filename)` and `self.assertEquals(len(changes['add']), 1)` you could write `self.assertEquals(changes['add'], [filename])`.