Test Framework for Eclipse RCP Application
Asked Answered
C

4

7

I am new to Eclipse RCP and I'm looking for an open source framework to test my RCP application (especially the GUI). I want to run this tests as unit tests.

Can you suggest some good frameworks with which you made good experiences?

Commissionaire answered 28/4, 2011 at 12:21 Comment(0)
E
6

The eclipse platform builds come with an Junit Plug-in test framework that allows JUnit tests written as plugins to run in the context of an Eclipse or RCP app. The JUnit plugin tests could then use SWTBot as well as the standard platform API (open windows, show views, etc).

See http://www.eclipse.org/articles/Article-PDE-Automation/automation.html to get started.

See also Automating unit tests (junit) for Eclipse Plugin development

Eminent answered 29/4, 2011 at 13:19 Comment(0)
E
2

You may want to try SWTBot. It is made explicitly for the SWT UI. It is in incubation still but under active development.

Equable answered 28/4, 2011 at 12:27 Comment(1)
@Commissionaire you're welcome, BTW I seem to have missed the unit test part of your question. Testing the UI with SWTBot would automatically result in an integration test. It tests if certain UI input produces certain UI output, so a test could fail for more reasons than a missing button. The rest of your RCP application can be unit-tested with plain old JUnit.Equable
S
1

I had a presentation on EclipseCon '11 about this subject: 10 Techniques to Test a Plug-in.

Supersedure answered 24/6, 2011 at 19:51 Comment(0)
E
1

You coud try WindowTester Pro - this used to be a commercial product, but after Google bought it it open sourced it and now it it is free, it is good actually http://code.google.com/javadevtools/wintester/html/index.html

Eupepsia answered 11/10, 2011 at 7:35 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.