improve CURL tests to allow testing without separate server