use method to get port instead of property, add event to notify plugins of test phase prepared