Я просто пытаюсь выполнить какой-то базовый автоматический тест e2e с использованием транспортира. однако я столкнулся с этой ошибкой, на которую не нашел ответа в интернете.
Я проверил связанные вопросы и ответил на них в переполнении стека, но ни один из них не решил мою проблему.
файл конфигурации:
`` `
// An example configuration file
exports.config = {
framework: 'jasmine',
// The address of a running selenium server.
seleniumAddress: 'http://localhost:4444/wd/hub',
// Capabilities to be passed to the webdriver instance.
capabilities: {
browserName: 'firefox',
},
specs: ['./todo-spec.js']
// Options to be passed to Jasmine-node.
};
spec file:
describe("Protractor Demo App", function() {
it("should have a title", function() {
browser.get("http://juliemr.github.io/protractor-demo/");
expect(browser.getTitle()).toEqual("Super Calculator");
});
});
error log:
Failures:
1) Protractor Demo App should have a title
Message:
Expected [object Promise] to equal 'Super Calculator'.
Stack:
Error: Expected [object Promise] to equal 'Super Calculator'.
at <Jasmine>
at UserContext.<anonymous> (E:\protractor\todo-spec.js:4:32)
at <Jasmine>
1 spec, 1 failure
Finished in 0.047 seconds
C:\Users\M1049161\AppData\Roaming\npm\node_modules\protractor\node_modules\jasmine-core\lib\jasmine-core\jasmine.js:3190
throw arguments[0];
^
Error: Error while waiting for Protractor to sync with the page: "both angularJS testability and angular testability are undefined. This could be either because this is a non-angular page or because your test involves client-side navigation, which can interfere with Protractor's bootstrapping. See http://git.io/v4gXM for details"
at ProtractorBrowser.<anonymous> (C:\Users\M1049161\AppData\Roaming\npm\node_modules\protractor\built\browser.js:354:27)
at Generator.next (<anonymous>)
at fulfilled (C:\Users\M1049161\AppData\Roaming\npm\node_modules\protractor\built\browser.js:4:58)
at process._tickCallback (internal/process/next_tick.js:68:7)