views:

38

answers:

1

I am working on a project that is developing a webapp with a 100% Flex UI that talks via Blaze to a Java backend running on an application server. The team has already created many unit tests, but have only created integration tests for the persistence module. Now we are wondering the best way to integration test the other parts. Here are the Maven modules we have now, I believe this is a very typical design:

Server Side:

1) a Java domain module -- this only has unit tests

2) a Java persistence module (DAO) -- right now this only has integration tests that talk to a live database to test the DAOs, nothing really to unit test here

3) a Java service module -- right now this only has unit tests

Client Side:

4) a Flex services module that is packaged as a SWC and talks to the Java backend -- currently this has no tests at all

5) a Flex client module that implements the Flex UI on top of the Flex services module - this has only unit tests currently (we used MATE to create a loosely couple client with no logic in the views).

These 5 modules are packaged up into a WAR that can be deployed in an application server or servlet container.

Here are the 4 questions I have:

  1. Should we add integration tests to the service module or is this redundant given that the persist module has integration tests and the service module already has unit tests? It also seems that integration testing the Flex-Services module is a higher priority and would exercise the services module at the same time.
  2. We like the idea of keeping the integration tests within their modules, but there is a circularity with the Flex services module and the WAR module. Integration test for the Flex services module cannot run without an app-server and therefore those tests will have to come AFTER the war is built, yes?
  3. What is a good technology to integration test the Flex client UIs (e.g. something like Selenium, but for Flex)?
  4. Should we put final integration tests in the WAR module or create a separate integration testing module that gets built after the WAR?

Any help/opinions is greatly appreciated!

+1  A: 

More an hint than a strong answer but maybe have a look at fluint (formerly dpUInt) and the Continuous Integration with Maven, Flex, Fliunt, and Hudson blog post.

Pascal Thivent
Nice link. We are using Hudson as our CI tool, so that was nice to read about. However, we are already using FlexUnit for the Flex unit tests. The article, while addressing the process of continuous integration, didn't address "integration testing" which apparently, they do not do :-( which is too bad.
HDave
@HDave I wanted at least to mention fluint which is advertised as a *Flex Unit and Integration Testing Framework*. But I must say that don't have any practical experience in that field, my knowledge of Flex and BlazeDS is very limited.
Pascal Thivent