by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 14:20

    christian-bromann on master

    v6.1.24 (compare)

  • 14:20

    christian-bromann on v6.1.24

    (compare)

  • 13:12
    Amrkamel1 edited #5557
  • 12:49
    mikesalvia synchronize #5540
  • 08:01

    christian-bromann on master

    Add missing typescript typings … (compare)

  • 08:01
    christian-bromann closed #5564
  • Jul 01 23:09
    christian-bromann closed #5565
  • Jul 01 23:09
    christian-bromann closed #5398
  • Jul 01 23:09
    christian-bromann labeled #5565
  • Jul 01 21:52
    emilyrohrbough synchronize #5565
  • Jul 01 21:45
    emilyrohrbough opened #5565
  • Jul 01 19:46
    mikesalvia commented #5540
  • Jul 01 17:24
    christian-bromann commented #5564
  • Jul 01 16:53
    SrinivasanTarget commented #5564
  • Jul 01 16:52
    SrinivasanTarget synchronize #5564
  • Jul 01 16:02
    pmerwin commented #5562
  • Jul 01 15:17
    christian-bromann labeled #5564
  • Jul 01 15:15
    SrinivasanTarget opened #5564
  • Jul 01 13:00
    christian-bromann labeled #5563
  • Jul 01 13:00
    christian-bromann commented #5563
Martijn Kuhlemeier
@martijnhjk
Hey, does anyone know if you can define custom matchers for expect-webdriverio? there is no mention about it here: https://webdriver.io/docs/api/expect.html
Erwin Heitzman
@erwinheitzman
Not sure but quite likely as it's just an extension @martijnhjk I'd just try it out as it's the fastest way to an answer to that question
12 replies
@kraggerz not sure if I am right on this but I think you need to extend you app with the WebdriverIO types
Olga
@osmolyar
@Lecale then you can try the xpath 'or' syntax; iframe(src='ExampleApp') or iframe(src='exampleapp')
Lecale
@Lecale
okay, i will try that. Is it in the webdriverio docs? I don't find it.
Erwin Heitzman
@erwinheitzman
@Lecale sounds like a nice thing to fix in the frontend code rather then to create a workaround in the test ;)
Lecale
@Lecale
tell me about it :)
Olga
@osmolyar
@Lecale it's not in the webdriverio docs; just basic xpath operators: https://www.w3schools.com/xml/xpath_operators.asp.
But actually something like this might be better:
 //iframe[contains(lower-case(@src), ‘exampleapp’)]
Olga
@osmolyar
Documentation for xpath contains syntax: https://www.scientecheasy.com/2019/11/xpath-contains-text.html/
Olga
@osmolyar

@Lecale Apparently there's also a 'matches' option with a case-insensitive flag 'i' in xpath 2.0:

//iframe[matches(@src,'exampleapp','i')]

Ref. https://stackoverflow.com/questions/2893551/case-insensitive-matching-in-xpath

alorlov
@alorlov
Hi, there is beautiful app for VSCode Mocha Test Explorer which allow to run tests individualy through editor UI. I just can not figure out if it can be used for WebdriverIO as well?
image.png
Felix Ivan Romero Rodríguez
@firomero

Hi, faced the issue of stand-alone seleniun driver, there is already a solution?

Could not load plugin wdio from module './plugin/wdio':
Couldn't initialize service selenium-standalone from wdio plugin config.
It should be available either in '@wdio/selenium-standalone-service' package

My config is as follow

{
  "name": "automate-qa",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [],
  "author": "felix<firomerorom4>",
  "license": "ISC",
  "dependencies": {
    "@codeceptjs/ui": "^0.3.8"
  },
  "devDependencies": {
    "@wdio/selenium-standalone-service": "5.16.10"
  }
}

Installed codecepts globally

kblain1967
@kblain1967
So, I've been running my tests using webdriver.io v6 with 2 capabilities: chrome and firefox. It seems at max instances of 1, it runs both capabilities in parallel. Is this expected? And, if I had 10 different capabilities defined, would it run 10 test specs at a time? Is there a way to limit this? Also, on webdriver.io v5, it used to run each test spec on each capability serially.
Olga
@osmolyar
@firomero , I imagine you need to install and run wdio to load @wdio/selenium-standalone-service
Orane Findley
@ofindley
Using webdriver v5 whats the best/recommended way to set the date on a calendar field?
Samuel Freiberg
@samuelfreiberg
Has anyone performed some type of accessibility testing for a React-Native windows application using WebDriverIO?
Felix Ivan Romero Rodríguez
@firomero

@firomero , I imagine you need to install and run wdio to load @wdio/selenium-standalone-service

yes

Olga
@osmolyar
It's not in your package.json dependencies though. So you must be using a global wdio? The global wdio may not see the local @wdio/selenium-standalone-service. Recommend having all packages available locally.
JI
@J-JRC
Hey Everyone
Is it a known issue that moveTo function does not work on Safari? is there any workaround?
HardKode
@HardKode

Context: webdriverIO v5
Issue : console ouput variation makes me think local runner doesnt shutdown properly
Normal console log :

Spec Files:     1 passed, 1 total (100% completed) in 00:00:16 

2020-05-22T19:48:56.766Z INFO @wdio/local-runner: Shutting down spawned worker
2020-05-22T19:48:57.018Z INFO @wdio/local-runner: Waiting for 0 to shut down gracefully
2020-05-22T19:48:57.018Z INFO @wdio/local-runner: shutting down

Suspected issue console:

[firefox 3.10.0-1062.4.3.el7.x86_64 linux #0-0] 29 passing (10m 3.4s)


Spec Files:     1 passed, 1 total (100% completed) in 00:10:08

This matters because I am running it in a script that should return 0 and I am wondering why the difference in console ouput.

Jeremy Schneider
@YmerejRedienhcs

My screenshots on failure are not happening as I want. I have this as my afterTest function:

  afterTest: function (test) {
    if (!test.passed) {
      const secs = Math.floor(new Date().getTime() / 1000);
      const fname = `${encodeURIComponent(test.title.trim().replace(/\s+/g, '-'))}_${secs}.png`;
      const fp = join(process.cwd(), this.screenshotPath, fname);
      console.info(`saving screenshot: ${fp}`);
      browser.saveScreenshot(fp);
    }
  },

but it doesn't seem to happen right at the point of failure, but rather, later, after the bad page state is no longer shown. What would be causing this, and how can I work around/fix it?

Felix Ivan Romero Rodríguez
@firomero

It's not in your package.json dependencies though. So you must be using a global wdio? The global wdio may not see the local @wdio/selenium-standalone-service. Recommend having all packages available locally.

thanks a lot

Nitin Venkat Rachabathuni
@NitinBuzz
Hey All, any hints on how to test md-select ?
Erwin Heitzman
@erwinheitzman
@NitinBuzz
$('md-select[someUniueAttribute="someUniqueValue"]').click();
$('md-option[ng-value="someUniqueValue"]').click();
something like that
and this goes for any select
sometimes the options are part of the select and sometimes not but the basics stay the same
@YmerejRedienhcs that can happen if the command triggered an action that caused your test to fail but wasn't expected in the test
Erwin Heitzman
@erwinheitzman
What would be causing this, and how can I work around/fix it? => can you provide more info on what it is you get and what you expect?
Nitin Venkat Rachabathuni
@NitinBuzz

sometimes the options are part of the select and sometimes not but the basics stay the same

Thanks Erwin :)

Vahan
@MeVa85_twitter
Is it possible to get the WebElement type object in wdio? The return type of $('selector') is WebdriverIO.Element
Ambreen Khan
@arkhangelsk
Anyone have experienced this error while running the test:
ERROR @wdio/local-runner: Failed launching test session: TypeError: Cannot convert undefined or null to object for node_modules/@wdio/sync/build/executeHooksWithArgs
As a result of this error, it shows an additional failed Test case…If I run 1 TC that is passed, it shows 1 Passed, 1 Failed!
Luc Verdier
@Verdier
Hi there, some one know why the browser restarts after each test file, even when grouped inside a suite? Is there a way to prevent this behavior? I have search in every part of the documentation but there is no other mention that a very old restart: false which looks to be deprecated... :/
Phil Merwin
@pmerwin
@alorlov Man that is awesome , thanks for the tip!
Baha
@hijazi
Hi guys, in wdio v4 there was a swipe command, now there isn't, and there's a touchAction command that only works with Appium, but I need to test a slide swipe functionality on my laptop on the browser, do you have any idea how to do that?
I'll try something like this:
browser.execute(() => {
        // @ts-ignore
        (document as HTMLDocument).querySelector('html').scroll();
    });
Daljit Singh
@daljit08_gitlab

Hi , am getting an abrupt error without much showing in the context with appium 1.17.1 and webdriverIo any version. So i assume its appium issue. if anything incorrect providedin config or a loose wire connection to devices or any other things, running the script always shows

ERROR webdriver: RequestError: read ECONNRESET. always shows this generic message.

Earlier with appium 1.15.1 it shows some specific error string e.g device of os 10 not found or etc...
so does it something with node_modules as i have 12.17.0. or what?

Jayshreekant Shreevastava
@jayshreekant
@christian-bromann how to scroll vertically in appium for ios and android.

Hi , am getting an abrupt error without much showing in the context with appium 1.17.1 and webdriverIo any version. So i assume its appium issue. if anything incorrect providedin config or a loose wire connection to devices or any other things, running the script always shows

ERROR webdriver: RequestError: read ECONNRESET. always shows this generic message.

Earlier with appium 1.15.1 it shows some specific error string e.g device of os 10 not found or etc...
so does it something with node_modules as i have 12.17.0. or what?

@daljit08_gitlab Scroll above ECONNRESET, you will find the elaborated error, it is mostly configuration issue

@christian-bromann how to scroll vertically in appium for ios and android.
GYANENDRA PANDEY
@gyanendrapmca

setValue | keys command?

It's not working, due to keyboard enabled here- i faced same issue in appium/java also and resolve using this- driver.getKeyboard().sendKeys("jschwartz"); But, i didn't found anything here, how to handle this thing.

??

Daljit Singh
@daljit08_gitlab
@jayshreekant There is nothing above that line. what configuration error it was showing in appium 1.15.1 but with 1.17.1 its showing common error for all the error whether configuration or connection problem or missing .apk file etc.
GYANENDRA PANDEY
@gyanendrapmca
browser.keys - throwing error - URL '/session/379ca633-968e-45b5-bdfc-758233a09117/actions' did not map to a valid resource and close the application, someone please help regarding this, how to resolve this one?
Olga
@osmolyar
@Verdier , do you have a browser.reload() in any hooks?
@arkhangelsk , given the error with /executeHooksWithArgs, do you have any hooks being called with arguments?
Olga
@osmolyar
@YmerejRedienhcs I would suggest putting the screenshot logic in an afterStep hook, not afterTest, since by the time afterTest runs some other things may have happened (e.g., a reload)
@HardKode are you using a different loglevel setting between the two variations?
GYANENDRA PANDEY
@gyanendrapmca

browser.keys - throwing error - URL '/session/379ca633-968e-45b5-bdfc-758233a09117/actions' did not map to a valid resource and close the application, someone please help regarding this, how to resolve this one?

??

chirag-farfetch
@chirag-farfetch
Hello, does anyone know how can i use this locator? do i need to put any question around /n?