add test for socket