added get port method & tests