Rob Audenaerde
Rob Audenaerde

Reputation: 20029

Multi-user test approach for wicket application

We are developing a Wicket Application where users can log in and perform searches on a Lucene index. They can also modify their own, small index.

We have great test coverage for single-user scenarios. However, as the application is intended to be run on a server and have multiple, concurrent users, I would like to be able to set-up a test that covers this scenario (e.g. 1 application, 10 concurrent users).

I have some experience using jmeter, but I would prefer a WicketTester-style approach if possible.

Does anyone have expercience setting up such a test? Or good pointers?

Upvotes: 0

Views: 220

Answers (2)

martin-g
martin-g

Reputation: 17513

I'm afraid it won't be possible to do what you need with WicketTester.

It starts one instance of the application. This is fine!
But it also acts like a browser, i.e. a single client. I have used http://databene.org/contiperf for some perf tests (non-Wicket) before and I liked it. But if you try to use it with WicketTester then you either will have to have a separate WicketTester for each user or you will face synchronization issues in WicketTester itself.

I'd recommend you to use JMeter or Gatling. A user from the community made this integration: https://github.com/vanillasource/wicket-gatling. I haven't used it yet but I hope to try it soon.

Upvotes: 1

Jogi
Jogi

Reputation: 21

We also use Wicket but concurrent users is not my main focus (no end-users). Sometimes I need to check cookie-behaviour, session-management etc. and then I use SAHI which also exists as open source IMO and as a demo. We use the Pro version also in other projects. From my perspective easy to learn and to handle.

_navigateTo("http://myapp/login.html");
// login as first user
...
// launch a new browser instance
var $instanceId = _launchNewBrowser("http://myapp/login.html");
_wait(5000);
// wait and select the new browser instance using the instanceId
_selectBrowser($instanceId);
// log in as second user
// send a chat message to first user
...

// Select the base window
_selectBrowser();
// view chat window and verify second user's chat message has arrived
...

Taken from documentation

Upvotes: 2

Related Questions