Due to the ever growing complexity and multiple dependencies of software components in an enterprise landscape, “Automated Testing” is no longer an optional feature of the software development process but a crucial ingredient of the development process and plays a significant role in every successfully launched software project.
Software Development in a SOA environment has its own challenges that differ from, let’s say, purely Java components. One reason is the fact that software testing needs invariant laboratory conditions; but exactly this is hard to achieve in a complex service landscape. So when designing tests it is very important to determine isolation conditions to meet these requirements. Another point worth keeping in mind is the fact that frameworks -like Oracle Fusion Middleware- follow a declarative development approach; this means that testing is possible only after the deployment and never before (because the services are de-facto built up during the deployment). Some artifacts can be tested before the deployment but we get to it later.
In this article focusing on Oracle Service Bus we outline a feasible testing strategy that allows us to implement automated testing of arbitrary complexity; starting from simple service-testing up to end-to-end tests that involve a whole service chain spread over one or more domains.
We assume that the reader is familiar with service classification concepts like “elementary services” or “composite services”. We also assume that the basic concepts of OSB like XQueries, Proxy and business services are well known concepts as well.
Let us focus for the moment on transformation logic. The tools offered by OSB are XQueries and XSLT transformations. These files describe, roughly speaking, how a certain XML structure should be transformed to another one, or how a piece of information can be extracted from it. Hence they can be regarded as functions that receive an XML structure as input and provide another XML structure or simple data as an output. These artifacts can be tested by java Junit means before deployment. One might consider of it as an unnecessary testing step; but it is enormous important, because it guarantees us that no side effects would remain undetected in case e.g. a namespace or a structural modification in a XML schema has to be carried out.
So keeping these points in mind, one can make the following distinction:
These are tests mainly using Junit techniques and may be considered as “low-level” or basic tests. They should guarantee that basic transformation logic of data structures meets the requirements. Testing the XQuery components help us ensure the XQuery language correctness as well and help us avoid namespace inconsistency and confusion. Read the complete article here.
For regular information on Oracle SOA Suite become a member in the SOA & BPM Partner Community for registration please visit www.oracle.com/goto/emea/soa (OPN account required) If you need support with your account please contact the Oracle Partner Business Center.