Please note that Sahi's development and support teams do not actively monitor this. This is more a community forum. If you are a Sahi Pro user looking for commercial support, please email support @ sahipro.com with your query.

Can't close current browser window and open new one to start next test

Hello,
I'm using sahi with firefox 33.1 and try to start sahi suite in parallel way. The problem exists when I have more tests in suite file than threads defined in testrunner.bat
For example:
in. regression.suite file i have:
test1.sah
test2.sah
test3.sah

in testrunner.bat i have:
SET THREADS=2
SET SINGLE_SESSION=false

I start sahi suite using tesrunner.bat and have result :

test1.sah start in browser1
test2.sah start ni broser2
when this 2 tests are finished the browsers are not closed and i have popup from firefox "Firefox is already running, but is not responding..." so test3.sah doesn't start.

When i set:
SET THREADS=3 all tests will be finished, but browsers will not be closed, this result doesn't satisfy me because when I have 50 tests in regression.suite i want to execute all in 5 browser instances not in 50 browsers. What's more I want to close browser when test is finished.

Answers

  • I had a popup because other instace of firefox (not from sahi) was opened.
    Still don't know how to close brower windows after test is finished.
  • Here is result of another test maybe it helsp diagnose the problem:

    1. When the configuration is:
    - restrunner.bat :
    SET THREADS=1
    SET SINGLE_SESSION=false
    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is correct:

    - First browser window is opened then start test1.sah and finish test1.sah
    - Then close first window, open window 2 and start test2.sah in window 2, ... etc.

    2. When configuration is:

    - restrunner.bat :
    SET THREADS=2
    SET SINGLE_SESSION=false

    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is :

    - Open window1 and open window2
    - Start test1.sah in window1 and start test2.sah in window2
    - close window1 and start test3 in window3
    result : for this momen corect
    - cant close window2 so test4.sah can't be started and firefox show popup:
    "Firefox is already running, but is not responding"





  • Here is result of another test maybe it helsp diagnose the problem:

    1. When the configuration is:
    - restrunner.bat :
    SET THREADS=1
    SET SINGLE_SESSION=false
    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is correct:

    - First browser window is opened then start test1.sah and finish test1.sah
    - Then close first window, open window 2 and start test2.sah in window 2, ... etc.

    2. When configuration is:

    - restrunner.bat :
    SET THREADS=2
    SET SINGLE_SESSION=false

    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is :

    - Open window1 and open window2
    - Start test1.sah in window1 and start test2.sah in window2
    - close window1 and start test3 in window3
    result : for this momen corect
    - cant close window2 so test4.sah can't be started and firefox show popup:
    "Firefox is already running, but is not responding"





  • Here is result of another test maybe it helsp diagnose the problem:

    1. When the configuration is:
    - restrunner.bat :
    SET THREADS=1
    SET SINGLE_SESSION=false
    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is correct:

    - First browser window is opened then start test1.sah and finish test1.sah
    - Then close first window, open window 2 and start test2.sah in window 2, ... etc.

    2. When configuration is:

    - restrunner.bat :
    SET THREADS=2
    SET SINGLE_SESSION=false

    - regression.suite file consists 4 test:
    test1.sah, test2.sah, test3.sah,test4.sah

    result is :

    - Open window1 and open window2
    - Start test1.sah in window1 and start test2.sah in window2
    - close window1 and start test3 in window3
    result : for this momen corect
    - cant close window2 so test4.sah can't be started and firefox show popup:
    "Firefox is already running, but is not responding"





Sign In or Register to comment.