having a bit of headache getting past basic auth for our uat environments, we have switched to using Appium and I am trying to configure Codeceptjs to allow me to pass through credentials.
My current config looks like :-
exports.config = {
output: './output',
helpers: {
Appium: {
path: '/wd/hub',
port: 4723,
platform: 'Android',
browserName: 'Chrome',
url: 'https://test.co.uk/',
basicAuth: {username: 'user', password: 'pass'},
show: true,
I have looked through the Codeceptjs docs and this should pass my credentials through, does Appium work differently? All I am doin is hitting a website on a mobile, any help would be gratelly appreciated.
Forgot to mention I am testing on Android/chrome, also reults at the momemnt the username/password posted in the url obviously result site can not be reached.
Finally figured it out, seems like having special characters in the username/password, was causing the problem, now resolved.
Related
Background: Here is my situation, I have a website I access that requires me to go through a proxy. For day-to-day use, I installed the chrome extension Proxy switchyomega to switch between proxies based on a URL wildcard. For example, when I go to URL abc.xyz.com my company requires me to use a proxy at x.x.x.x:yyyy.
Issue I am trying to write an automation script using WebdriverIO (version 7.24.0) in standalone mode using chrome that will launch the website abc.xyz.com. The problem is when I run the script it is not going through the proxy, so my access is blocked. I have tried to configure a proxy in the capabilities but that does not seem to work, and I'm wondering if I'm doing something wrong in my configuration, which is below
const { remote } = require("webdriverio");
const browser = await remote({
capabilities: {
browserName: "chrome",
proxy: {
proxyType: "manual",
httpProxy: "x.x.x.x:yyyy"
}
},
});
await browser.url("abc.xyz.com");
As mentioned in normal use when I access URL abc.xyz.com it routes through the x.x.x.x:yyyy proxy and that is what I need to happen when running my script but the above configuration does not seem to do anything.
Any help would be appreciated.
The website I am trying to access has ssl certificate-errors
I am using this version of puppeteer "puppeteer": "1.13.0".
When I try to await page.goto('http://bad_ssl_certificate_website') I have timeout error on google cloud only.
TimeoutError: Navigation Timeout Exceeded:
However, It works perfectly fine locally on MAC.
I think the problem is ssl-certificate-errors for my website, because if I try with "google.com" it works okay in both environments.
I used https://www.sslshopper.com to check ssl certificates,and It mentioned this.
The certificate is not trusted in all web browsers. You may need to
install an Intermediate/chain certificate to link it to a trusted root
certificate. Learn more about this error. You can fix this by
following DigiCert's Certificate Installation Instructions for your
server platform. Pay attention to the parts about Intermediate
certificates.
When I was using older version of puppeteer I had problems locally as well.
I saw the exactly the same error
'TimeoutError: Navigation Timeout Exceeded:'
Updating to the newest version of puppeteer has fixed only running the puppeteer locally, but it has not fixed the puppeteer running on google cloud
This is how I setup puppeteer to lunch.
const browser = await puppeteer.launch({
headless: true,
ignoreHTTPSErrors: true,
args: [
"--proxy-server='direct://'",
'--proxy-bypass-list=*',
'--disable-gpu',
'--disable-dev-shm-usage',
'--disable-setuid-sandbox',
'--no-first-run',
'--no-sandbox',
'--no-zygote',
'--single-process',
'--ignore-certificate-errors',
'--ignore-certificate-errors-spki-list',
'--enable-features=NetworkService'
]
});
I found some related issues:
https://bugs.chromium.org/p/chromium/issues/detail?id=877075
Just turn .IgnoreHTTPSErrors = True in the LaunchAsync constructor.
Example:
await new BrowserFetcher().DownloadAsync(BrowserFetcher.DefaultRevision);
var browser = await Puppeteer.LaunchAsync(new LaunchOptions()
{
Headless: true,
IgnoreHTTPSErrors: true
});
The --ignore-certificate-errors-spki-list actually accepts a whitelist of public key hashes ignore certificate-related errors. So it is used like: --ignore-certificate-errors-spki-list=jc7r1tE54FOO=
Chromium doc
I have a spinnaker local deployment running on ubuntu 14. I followed the notifications setup guide but its a bit fuzzy. I would appreciate any help in getting this integrated with slack.
Currently, I added a custom echo.yml with the slack configs. But its not picking up. Did not know where to specify custom settings.js (deck) as mentioned in the setup guide (https://www.spinnaker.io/setup/features/notifications/)
I would appreciate any hints/tips. Thanks!
cat /home/user/.hal/default/service-settings/echo.yml
slack: enabled: true token: some-token botName: spinnaker
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS Release:14.04
echo.yml
slack:
enabled: true
token: some-token
settings.js
notifications: {
slack: {
enabled: true,
botName: 'Spinnaker'
}
},
Under features at the bottom of settings.js make sure notifications is set to true.
Also you must invite the bot into the slack room, don't worry if the bot is shown as offline.
The latest Halyard allows you to do this with hal - no need for file overrides:
https://www.spinnaker.io/reference/halyard/commands/#hal-config-notification-slack
I trying to setup RestComm Web SDK demo application on my local system, I just want to create an application for audio/video, chat, IVR, etc(RestComm provide me perfect solution for my needs). Now I have setup RestComm Web SDK on my local system and whenever I an trying to sip call, It throws WebRTCommClient:call(): catched exception:NotSupportedError: Failed to construct 'RTCPeerConnection': Unsatisfiable constraint IceTransports on browser console.
My webRTC confrigration is as below:
// setup WebRTClient
wrtcConfiguration = {
communicationMode: WebRTCommClient.prototype.SIP,
sip: {
sipUserAgent: 'TelScale RestComm Web Client 1.0.0 BETA4',
sipRegisterMode: register,
sipOutboundProxy: parameters['registrar'],
sipDomain: parameters['domain'],
sipDisplayName: parameters['username'],
sipUserName: parameters['username'],
sipLogin: parameters['username'],
sipPassword: parameters['password'],
},
RTCPeerConnection: {
iceServers: undefined,
stunServer: 'stun.l.google.com:19302',
turnServer: undefined,
turnLogin: undefined,
turnPassword: undefined,
}
};
While I can use olympus without any issue in Chrome Browser. I am stuck with this exception, any suggestions would be highly appreciated.
I think the problem here is that the version of Webrtcomm library inside the demo application you are using is outdated and doesn't include a fix for latest Chrome version. So please replace samples/hello-world/scripts/WebRTComm.js within your repository, with:
https://github.com/RestComm/webrtcomm/blob/master/build/WebRTComm.js
That should fix your issue.
Best regards,
Antonis Tsakiridis
i,m having a runtime error when i execute a webdriverIO test by console.
this is the error Couldn't connect to selenium server to execute a webdriverIO test.
I can access to my selenium server by browser (http://localhost:4444/wd/hub/static/resource/hub.html) but its still not working.
Please, can anyone help me.
thanks a lot for the help.
Have you tried this solution?
https://github.com/webdriverio/webdriverio/issues/602
Specifically, adding:
var options = {
desiredCapabilities: {
browserName: 'chrome'
},
host: 'localhost',
port: 4444
};
Worked for me.
Very long time after, but I faced this issue with Appium and I'd like to share what I find to solve it in case someone else face it with Appium.
Open Appium server application and start the server with host: 127.0.0.1 and port: 4723.
Open your Emulator or connect device.
Run again the instruction to execute it.
As per the docs:
Handling the Selenium server is out of scope of the actual WebdriverIO project.
So we need to either go with raw ChromeDriver or spin up the Selenium grid. When running with the latter and setting
WebDriver: {
url: '<your-vaue-here>',
browser: 'chrome',
host: '127.0.0.1',
port: 4444,
...
don't forget to disable the codecept.config.js section, like this:
services: [
['']
],
...
Otherwise both servers will try to use http://localhost:4444.
Caveat:
When executing codeceptJS tests in parallel via run-workers I observe flaky behaviour as some threads actually kill the Selenium grid while others are still running. To resolve this issue, disable the services section and run a dedicated Grid server as initial step in your CI pipeline (assuming this is the place you actually need the parallelism).