small cleanup and refactoring
finishing tests for Object.copy and Object.isEmpty