Fix issue when copying folders.
Fix cp tests.