Move directories_equal to helpers.py.