We have a complex system, shown in the diagram below, consisted of 3 interacted systems: A, B and C. Each system has own database, services and UI layers. Systems communicate via HTTP protocol.
Basic work-flow of complex system is following: user creates deal in system A, which stores deal in its own database and pushes it to the system B. In the system B deal is validated and stored in its own database. User can view, edit and manage deal’s entitlements with UI of system B. System C periodically pulls data from system B and again stores it in its own database. Finally, user can view deals with UI of system C.
We assume that systems A, B and C are covered by separate automated integration tests. These systems are developed by different teams (but of the same company), have separate code bases and use different languages (Java, C#). The task is to create automated end-to-end service-layer tests (also so-called Subcutaneous Tests) for whole complex system. Selected language for tests is C#.
Here is simplified example of end-to-end test scenario which needs to be automated:
- User creates deal in system A
- User searches for created deal with system B’s UI and ensures that deal is found
- User searches for created deal with system C’s UI and ensures that deal is NOT found
- User change deal’s entitlements with system B’s UI User searches for created deal with system C’s UI and ensures that deal is found
So far there are 2 approaches to creating automated end-to-end tests suggested by members of our team:
- To reuse existing automated integration tests of particular systems in end-to-end tests. For this purpose special framework is supposed to be created which will play role of “orchestrator” that is: run tests for particular systems in appropriate order and manage data exchange between them. In this case tests of course need to be aware of custom framework.
- To create automated end-to-end tests for complex system independently from existing integration tests for particular systems. Each test is supposed to be self-contained and can be run in arbitrary order by general-purpose test runner (i.e. XUnit). In doing so reuse of existing test’s code of course is desirable where it is possible.
Please help us to choose between approaches described above or suggest different ones.
Aucun commentaire:
Enregistrer un commentaire