'Wait until the JS result arrived and compare it.'

def check(self, expected):

    if (self._result is self.UNSET):
        with self._qtbot.waitSignal(self.got_result):
            pass
    assert (self._result == expected)
