Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] SWTBOT switch workspace problem

Thank you for your response,
Yes, I thought of making each test run in a separate workspace, but I didn't figure out how to do that from tycho, or even from the test itself. Do you have any suggestion how it could be done ?

Regards,
Mohamed Azab 

On Thu, Aug 9, 2012 at 4:48 PM, Sievers, Jan <jan.sievers@xxxxxxx> wrote:

AFAIK switching the workspace in eclipse means low-level restart (I think the JVM dies and only the native launcher survives and relaunches the JVM with a different workspace)

This will break the tycho surefire test harness.

 

Therefore I would discourage switching workspace during test execution and try to find other solutions instead (separate test runs with different workspaces?)

 

Regards

Jan

 

From: tycho-user-bounces@xxxxxxxxxxx [mailto:tycho-user-bounces@xxxxxxxxxxx] On Behalf Of Mohamed Azab
Sent: Donnerstag, 9. August 2012 15:51
To: Tycho user list
Subject: [tycho-user] SWTBOT switch workspace problem

 

I am using SWTBOT with tycho-surfire to test an eclipse application. The tests runs individually fine, but when I combine them I need to switch the workspace after each test, or specify somehow a specific workspace for each test. When I try to switch the workspace from inside the test with this code:

 
bot.menu("File").menu("Switch Workspace").menu("Other...").click();
bot.shell("Workspace Launcher").activate();
String workspace = bot.comboBoxWithLabel("Workspace:").getText() + "/ResetButtonTest";
bot.comboBoxWithLabel("Workspace:").setText(workspace);
bot.button("OK").click();

the simulator reaches the OK button and press it, the workbench closes but never starts again. There was an error asking to set the property eclipse.vm, and I did. The error is gone but still can not switch the workspace.

Is there any configuration file or something that I can add to tyco-surfire to configure SWTBot to have a specific workspace for each test it runs? Or even to run each test in a new workbench, and not to continue in the same workbench? Or is there any solution that fixes the problem of switching the workspace from inside the test?

 

Regards,

Mohamed Azab


_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/tycho-user



Back to the top