Pergunta

I have what I think are standard functional tests set up for the intern and I can get them to pass consistently in several browsers. I'm still evaluating if it makes sense to use the intern for a project so I'm trying to see what happens when tests fail, and currently if I make one test fail, it always seems to cause all the tests in the suite to fail.

My tests look a bit like :

registerSuite({name : 'demo',
  'thing that works' : function () {
      return this.remote.get('http://foo.com')
                        .waitForCondition("typeof globalThing !== 'undefined'", 5000)
                        .elementById('bigRedButton')
                          .clickElement()
                        .end()
                        .eval('jsObj.isTrue()')
                        .then(function(result){
                          assert.isTrue(result);
                        })
                        .end(); // not sure if this necessary...
  },
  'other thing that works': function() {
     // more of the same
  }
});

I'm going to try and debug to figure out this for myself, but I was just wondering if anyone knows if this is expected behaviour (1 test failure causes whole test suite to fail, and report that all tests in suite have failed), or whether its more likely that my set up is wrong and I have bad interactions between the promises or something?

Any help would be awesome, and happy to provide any more info if helpful :)

Thanks!

Foi útil?

Solução

I ran into the exact same issue a few weeks ago and created a ticket on github for the issue: https://github.com/theintern/intern/issues/46.

It's tagged 'needs-triage' at the moment, I've no idea of what it means.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top