adds test server and fixes tests