Improve integration tests, fix configuration reading