Unit test for copy_key bucket validation.