Improve tests for Socket service