by

Where communities thrive


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

    christian-bromann on master

    v6.1.24 (compare)

  • Jul 02 14:20

    christian-bromann on v6.1.24

    (compare)

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

    christian-bromann on master

    Add missing typescript typings … (compare)

  • Jul 02 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
Christian Bromann
@christian-bromann
this increases the timeout
Johan Thallauer
@JohanTh

that still gave me:

AssertionError: expected undefined to be true

Christian Bromann
@christian-bromann
mhm..and how about:
return this.client
    .waitForExist("selector", 5000, true)
    .isExisting("selector")
    .should.eventually.be.false;
Johan Thallauer
@JohanTh
oh no, sorry, the problem is that I'm an idiot. I had two steps with almost identical names who was doing checks on the same element. What's in the cheat sheet works.
Miguel Rivera
@miguelrivera
Guys, does anyone know how to set a certain screen resolution when using phantomjs? I suspect it must be some capability one adds, right?
Christian Bromann
@christian-bromann
@miguelrivera just call http://webdriver.io/api/window/setViewportSize.html right after calling init
Miguel Rivera
@miguelrivera
of course you had a method for that, damn this driver is good!
Christian Bromann
@christian-bromann
;)
even two, one for setting the viewport and one for setting window size ;)
Miguel Rivera
@miguelrivera
That was my next question, haha
Christian Bromann
@christian-bromann
but I am not sure if these work in phantomjs since it is a headless browser
Miguel Rivera
@miguelrivera
Worked just fine!
Christian Bromann
@christian-bromann
cool
Miguel Rivera
@miguelrivera
btw, any suggestions on the best way to wait for a modal backdrop to go away?
Christian Bromann
@christian-bromann
all waitfor commands have a reverse flag so waitforexist is like waitforwentaway or sth like this
Miguel Rivera
@miguelrivera
Ok
Dan Dascalescu
@dandv
I'd like to have one test suite in Gherkin syntax, and run it against some headless browser first (which one, is another good question) before running it against Selenium in the cloud (which is slow and expensive). How can I do that? Is it also likely that some tests may fail in the headless browser but they'll work in a real browser? If so, how can I specify in the test suite or config files that certain tests are to be run only against Selenium?
Dan Dascalescu
@dandv

@dandv I was experimenting with fibers to get sync in webdriverio .. got it working for protocol commands but not for nested commands, definitelly something I wanna add to webdriverio

Is there any work underway from the Xolvio guys, or only plans at this stage? https://github.com/meteor-velocity/velocity/issues/254#issuecomment-127039842 Curious if they got in touch with you (I'm a Meteor user).

Miguel Rivera
@miguelrivera
Anyone who's has tried to trigger client side events? For instance to trigger the change event on a certain <input>?
slawomir-brzezinski-at-travcorp
@slawomir-brzezinski-at-travcorp
I'm running WDIO with cucumber. For debugging purposes, what's the best way to make it not close the browser when the test fails?
Johan Thallauer
@JohanTh
can we click a <a href="findThis">link</a> by its href value?
Miguel Rivera
@miguelrivera
@JohanTh Yep... browser.click("a[href=\"findThis\"]")
Johan Thallauer
@JohanTh
ohh thank you :)
Jaroslav Kubíček
@jaroslav-kubicek
Hi, I was looking forward to update that will cause that waitForXXX fails when element isn't found before timeout, it was already implemented, but then it was rewritten back to original: webdriverio/webdriverio@59e3c79 Is there any plan to change it or some good practice how to deal with it? I want to write the smallest possible amount of code like this:
it 'wait for load', (done) ->
  client.waitForExist 'selector', done
Christian Bromann
@christian-bromann
@dandv headless browser: checkout phantomjs http://phantomjs.org/, install and do in your config: browserName: “phantomjs”, yes this might be likely but a common case - phantomjs is good for developing/writing your test specs and then run them across different browser in your ci system, it might be a good idea to have multiple config files for dev and ci environment

Is there any work underway from the Xolvio guys, or only plans at this stage?

I am in contact with the sam and sanjo. Last one got fibers working in chimp which looks really awesome. I haven’t had much time to port that fully to webdriverio. My plan is to let user decide how to handle async. people will be able to decide whether they want to write synchronous tests only, promise chains only or a mixure using promises and yield .. so excited for that

Christian Bromann
@christian-bromann

Anyone who's has tried to trigger client side events? For instance to trigger the change event on a certain <input>?

nope, you can inject javascript to trigger it, using addCommand you can make yourself handy commands to invoke different events. Wondering if something like a trigger command would be useful that would fullfil such thing (would only work in desktop browser though)

I'm running WDIO with cucumber. For debugging purposes, what's the best way to make it not close the browser when the test fails?

make use of the debug command: http://webdriver.io/api/utility/debug.html .. it let you jump into the browser before an assertion

Christian Bromann
@christian-bromann
@jaroslav-kubicek in v3 please use promises to handle errors:
it('wait for load', function(done) {
  client.waitForExist('selector').catch(done).call(done);
});
more convenient:
function seal(cb) {
    return function() {
     cb();
   }
}

it('wait for load', function(done) {
  client.waitForExist('selector').then(seal(done), done);
});
Jaroslav Kubíček
@jaroslav-kubicek
great, that’s enough, thanks!
Miguel Rivera
@miguelrivera
@christian-bromann when it comes to passing in custom parameters to the wdio runner...? Do you have any tips? I'd like to pass in user/pass for different environments... or is it possible to access the wdio runner configuration at runtime?
Christian Bromann
@christian-bromann

or is it possible to access the wdio runner configuration at runtime?

No

when it comes to passing in custom parameters to the wdio runner…?

I recommend to have a common config file that contains all things that don’t change in your environments. Then have a config file for each of them and require your main config file and merge your common configs with your env specific configs

Dan Dascalescu
@dandv
Regarding merging config files: webdriverio/cucumber-boilerplate#1
Vyacheslav Slinko
@vslinko
is it possible to configure Accept-Language header?
Dan Dascalescu
@dandv
@christian-bromann If https://github.com/webdriverio/cucumber-boilerplate is meant for Cucumber, why does it use Mocha and Chai?
Dan Dascalescu
@dandv
  1. This code is pretty nice,
    it('should test something', function(done) {
    return client.click('#button').getValue('#someInput').then(function(value) {
     expect(value).to.be.exactly('some value');
    });
    });
    But what is the closest to return client.click('#button').getValue('#someInput') === 'some value' ?
Christian Bromann
@christian-bromann

is meant for Cucumber, why does it use Mocha and Chai?

it’s using yadda to enable cucumber like testing but in the background it is using mocha and chai for assertions

if you use cucumberjs you probably want to use an additional assertion library as well

But what is the closest to return client.click('#button').getValue('#someInput') === 'some value’ ?

we will probably get to a point where this is gonna be possible

Vyacheslav Slinko
@vslinko

is it possible to configure Accept-Language header?

@christian-bromann

Christian Bromann
@christian-bromann
you can do:
it('should test something', function(done) {
    yield client.click('#button’);
    expect(yield client.getValue('#someInput’)).to.be.exactly('some value');
});
@vslinko you mean for request in the browser?
Dan Dascalescu
@dandv
I thought CucumberJS included its own assertion library? http://custardbelly.com/blog/blog-posts/2014/01/08/bdd-in-js-cucumberjs/
Christian Bromann
@christian-bromann
cucumber-js does but not yadda
Dan Dascalescu
@dandv
I see. Is there an article I can read about the reasons for preferring yadda over cucumber for the boilerplate?
Christian Bromann
@christian-bromann
as I started to put this together I preferred yadda because they supported step tables
by now I guess both libraries are equally good
personally I like the the yadda code base more