change rights on cache dir, remove cache dir after tests