test passing Pathname object to constructor