how to close selenium webdriver at end of test?
问题 I have created a e2e test for my angular app. I would like to close down the selenium webdriver at the end of the test: describe('Selenium end', function () { it("close down selenium server", function () { browser.get('http://localhost:4444/selenium-server/driver/?cmd=shutDownSeleniumServer'); var text = element(by.css('pre')).getText(function (text) { expect(text).toEqual('OKOK'); }); }); }); When I run this i get: Message: Error: Error while running testForAngular: ECONNREFUSED connect