This repository was archived by the owner on Jul 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
This repository was archived by the owner on Jul 29, 2024. It is now read-only.
Webdriver.executeScript/Webdriver.schedule 'Method is not implemented' Error #3616
Copy link
Copy link
Closed
Description
- Node Version:
v4.4.5 - Protractor Version:
4.0.9 - Angular Version:
1.5.3 - Browser(s):
N/a - Operating System and Version
macOS Sierra 10.12 - Your protractor configuration file:
var appLocation = 'Absolute/path/to/the.app';
exports.config = {
seleniumAddress: 'http://localhost:4723/wd/hub',
specs: [
'features/*.feature'
],
framework: 'custom',
frameworkPath: require.resolve('protractor-cucumber-framework'),
cucumberOpts: {
require: ['features/step_definitions/*_steps.js', 'features/support/*.js'],
format: 'pretty'
},
capabilities: {
'appium-version': '1.6.0-beta2',
automationName: 'XCUITest',
platformName: 'iOS',
platformVersion: '10.0',
deviceName: 'iPhone 6s Plus',
browserName: "",
autoWebview: true,
fullReset: true,
app: appLocation
},
baseUrl: '',
onPrepare: function () {
var wd = require('wd'),
protractor = require('protractor'),
wdBridge = require('wd-bridge')(protractor, wd);
wdBridge.initFromProtractor(exports.config);
//To navigate using file:// rather than http://
var defer = protractor.promise.defer();
browser.ignoreSynchronization = true;
browser.executeScript( 'return window.location;' ).then( function(location){
browser.resetUrl = 'file://';
browser.baseUrl = location.origin + location.pathname;
defer.fulfill();
});
return defer.promise;
}
};
- A relevant example test:
https://github.com/flashquartermaster/myappname with capabilities upgarded to reflect:
'appium-version': '1.6.0-beta2',
automationName: 'XCUITest', - Output from running the test
$ ../node_modules/.bin/protractor ios-conf.js --troubleshoot
[17:19:14] D/launcher - Running with --troubleshoot
[17:19:14] D/launcher - Protractor version: 4.0.9
[17:19:14] D/launcher - Your base url for tests is
[17:19:14] I/hosted - Using the selenium server at http://localhost:4723/wd/hub
[17:19:14] I/launcher - Running 1 instances of WebDriver
[17:20:48] D/runner - WebDriver session successfully started with capabilities Capabilities {
'webStorageEnabled' => false,
'locationContextEnabled' => false,
'browserName' => '',
'platform' => 'MAC',
'javascriptEnabled' => true,
'databaseEnabled' => false,
'takesScreenshot' => true,
'networkConnectionEnabled' => false,
'appium-version' => '1.6.0-beta2',
'automationName' => 'XCUITest',
'platformName' => 'iOS',
'platformVersion' => '10.0',
'deviceName' => 'iPhone 6s Plus',
'autoWebview' => true,
'fullReset' => true,
'app' => '/Absolute/path/to/myappname.app',
'count' => 1 }
[17:20:48] D/runner - Running with spec files /PathTo/myappname/tests/features/login.feature
[17:20:50] E/launcher - Method is not implemented
[17:20:50] E/launcher - WebDriverError: Method is not implemented
at WebDriverError (/PathTo/myappname/node_modules/selenium-webdriver/lib/error.js:27:10)
at Object.checkLegacyResponse (/PathTo/myappname/node_modules/selenium-webdriver/lib/error.js:639:15)
at parseHttpResponse (/PathTo/myappname/node_modules/selenium-webdriver/http/index.js:538:13)
at /PathTo/myappname/node_modules/selenium-webdriver/http/index.js:472:11
at ManagedPromise.invokeCallback_ (/PathTo/myappname/node_modules/selenium-webdriver/lib/promise.js:1379:14)
at TaskQueue.execute_ (/PathTo/myappname/node_modules/selenium-webdriver/lib/promise.js:2913:14)
at TaskQueue.executeNext_ (/PathTo/myappname/node_modules/selenium-webdriver/lib/promise.js:2896:21)
at /UPathTo/myappname/node_modules/selenium-webdriver/lib/promise.js:2820:25
at /PathTo/myappname/node_modules/selenium-webdriver/lib/promise.js:639:7
at process._tickCallback (node.js:369:9)
From: Task: WebDriver.executeScript()
at WebDriver.schedule (/PathTo/myappname/node_modules/selenium-webdriver/lib/webdriver.js:377:17)
at WebDriver.executeScript (/PathTo/myappname/node_modules/selenium-webdriver/lib/webdriver.js:526:16)
at ProtractorBrowser.to.(anonymous function) [as executeScript] (/PathTo/myappname/node_modules/protractor/built/browser.js:62:29)
at exports.config.onPrepare (/PathTo/myappname/tests/ios-conf.js:47:17) (EDIT: Refers to this line: browser.executeScript('return window.location;').then( function(location){)
at /PathTo/myappname/node_modules/protractor/built/util.js:48:49
at Function.promise (/PathTo/myappname/node_modules/q/q.js:682:9)
at Object.runFilenameOrFn_ (/PathTo/myappname/node_modules/protractor/built/util.js:38:16)
at /PathTo/myappname/node_modules/protractor/built/runner.js:93:27
at _fulfilled (/PathTo/myappname/node_modules/q/q.js:834:54)
at self.promiseDispatch.done (/PathTo/myappname/node_modules/q/q.js:863:30)
[17:20:50] E/launcher - Process exited with error code 199
- Steps to reproduce the bug
Run the example above
- The URL you are running your tests against (if relevant)
N/a