2
votes
0answers
50 views

Play framework - testing POST controller method

I wanted to test one of my POST methods in my controller, so I written something like this: @Test public void shouldSaveNewCollectionToDatabase(){ String body = ...
2
votes
0answers
67 views

Writing non-GUI JUnit test cases for an app that relies on the SWT event loop being pumped on OS X?

I'm working on an SWT-based application on OS X, and I'd like to write some JUnit test cases (not automated GUI tests) on some utility code that requires the SWT event loop being pumped, but not ...
2
votes
0answers
60 views

Does JBehave works like Jasmine?

I love Javascript BDD Jasmine, as it is highly flexible to define the stories. The stories in Jasmine can be structured in a way that the prerequisite stories are ran before the stories that depended ...
2
votes
0answers
93 views

Can't access parent class methods in a JUnit test case

I'm trying to test an abstract class "Comando" which has a few dozen inherited classes. What I actually want to test are the many different chuld classes, to test each different behaviour ("Comando" ...
2
votes
0answers
382 views

App Engine Java Unit Test Environment Setup

we use the appengine-web.xml file to store global config data as system properties (like the location of various development servers we need to communicate with). These properties are not available ...
2
votes
0answers
353 views

Programmatic configuration of Struts in Jetty

I'm trying to configure struts2 within Jetty programmatically, but am having a lot of trouble doing so. As these are for 'unit' tests, I don't wish to use spring or any other 'DI Framework'. here is ...
2
votes
0answers
598 views

Verifying partially ordered method invocations in JMockit

I'm trying to write a unit test (using JMockit) that verifies that methods are called according to a partial order. The specific use case is ensuring that certain operations are called inside a ...
1
vote
0answers
67 views

Get menu item view Robotium

I know that I can get current views of a screen using getViews, I can then assert them or send appropriate commands. But can I also get similar views for menu items? May be a list of views for the ...
1
vote
0answers
37 views

Feasible database testing

I've been assigned with the task to investigate how we should perform our testing in an upcomming project. Im currently trying to decide whenever or not we should have structured tests for our SQL ...
1
vote
0answers
52 views

Mocking a Static Method without replayAll() in PowerMock

Does anyone know of a way to do a mock of a static class without calling replayAll()? I've seen many examples where people mock the Math.random() and use the replayAll(). To me it seems like ...
1
vote
0answers
33 views

Integration test file system dependent code in Java 7

I have a situation where I am revising a Java 5 application and I would like to add additional tests (unit tests bordering on integration tests) to ensure that things are working correctly. I need ...
1
vote
0answers
26 views

Path or naming shema for files with classes that marked by @SuiteClasses (JUnit4)

Today I trapped into problem with @SuiteClasses. I recently joined to new project with relatively young/unexperienced team and found drawbacks in project testing architecture: Test files with ...
1
vote
0answers
26 views

Unit Testing libraries for blackberry

I'm developing a library for a BB 5.0 app, however I don't know how to test this library without including it in a Application project. Is there a way of unit testing the code in my blackberry ...
1
vote
0answers
62 views

Can I configure JTidy to ignore certain errors and warnings?

I am using JTidy to validate snippets of HTML generated in Java a rendering class. I would like to ignore certain warnings and errors. (EDIT: On second thoughts I might not want to suppress errors) ...
1
vote
0answers
65 views

Can the TestNG “Failed Tests” output use line breaks?

When I run my TestNG tests I get the following truncated output for failed tests: Failed tests: retrievedDataFromService(com.mydomain.ServiceTest): The returned data is not correct:(..) The actual ...

1 2 3 4 5 15
15 30 50 per page