Testsuite Not working in some machines

I had a test suite which had 12 test cases in it and it is working perfectly fine on my machine(windows laptop) and the same test suite is getting failed in other machine.
I had set the step “Maximise browser” after opening the browser inside the test case, But it is failing and is throwing error that it is unable to find that element.
can someone help me with it.
Thanks.

@srianoop.d

Go to Project > Settings > Report and enable Take Screenshots when execution failed to see when a test fails, does the element exists (visible in the screenshot).

Hi @ThanhTo
I have seen the screenshots…The element is not visible in the screenshot.
In my machine it would scroll up to that element and it will click the element, But this is not happening in some machines and so the testsuite is failing. I was not able to find the exact reason because in some machines it is working and in some it is not.
Thanks in advance.

@srianoop.d

Please provide your test script for more details.

Hi @ThanhTo should i send the testcase where it is failing!!

@srianoop.d

If the test case is too long, then yes, otherwise the full test script would be great. Please note that you should provide the script around the failing step, not just from the step itself.

Hi @ThanhTo
I have added a step Scroll to Element and then it is working in the other machine also.
But i was thinking why in some machines it is working and in some it is not.
Thanks in advance

1 Like

I have had this problem where screen sizes and resolution were different between machines. Scroll to element into view resolves those differences.

@srianoop.d

So did Scroll to Element resolve the issue ? Like @danpoleary said, it’s possibly an issue of different screen resolutions between machines.

Yes @ThanhTo scroll to Element resolved the issue.

1 Like