banner



How To Create Mock Service In Parasoft Soa

What is SOA Testing?

SOA (Service Oriented Compages) Testing is a Testing of SOA architectural style in which the application components are designed to communicate via communication protocols typically over a network.

In this tutorial, you volition learn-

  • What is SOA?
  • What is Service?
  • SOA Testing
  • Strategy for SOA Testing
  • SOA testing methods
  • Challenges in SOA testing
  • SOA Testing Tools
  • SOA Testing Employ Cases

What is SOA?

SOA is a method of integrating business applications and processes together and so as to meet the business organization needs.

In Software Engineering, SOA provides agility and flexibility to business processes. The changes to the process or application can be directed to a item component without affecting the whole organization.

The software developers in SOA either develop or purchase chunks of programs called SERVICES.

What is Service?

Learn SOA Testing

  • Services can be a functional unit of measurement of application or business procedure, which can be reused or repeated past whatsoever other application or process.

    (For example, in the above image, Payment Gateway is a service which can exist reused past any eastward-commerce site. Whenever a payment needs to do, the e-commerce site calls/Requests the Payment Gateway service. Afterward payment is done on a gateway, a response is sent to the e-commerce website)

  • Services are easy to assemble and piece of cake to reconfigure components.
  • Services can be compared to building blocks. They can construct any application needed. Calculation and removing them from the application or business concern process is piece of cake.
  • Services are divers more than by the business organization office they perform rather than as chunks of code.

Spider web Services

Web services are independent application components, which are available over the web.

They can be published, found and can be used on the web. They can communicate through the net.

Learn SOA Testing

Learn SOA Testing

  1. The Service Provider publishes the service to the internet.
  2. The Customer searches for a item web service from the Spider web Service Registry
  3. A URL and the WSDL for the required web service is returned.

    >> Using the WSDL and the URL, the communication betwixt the service provider and the requestor happens through Soap messages. <<

  4. When a consumer calls a web service, an HTTP connection will be established to the provider.

    A SOAP bulletin is created to instruct the provider for invoking the required web service logic.

  5. The response received from the provider is a Soap bulletin which will exist embedded into the HTTP response. This HTTP response is the information format which is understandable by the consumer awarding.

Example

A home page of a Website and a Search Engine displays everyday atmospheric condition report. Instead of coding the weather report section all over, a Service of weather condition report can be bought from a vendor and integrated into the pages.

Learn SOA Testing

SOA Testing

SOA consists of various technologies. Applications built using SOA has various services which are loosely coupled.

Learn SOA Testing

SOA Testing should focus on 3 system layers

Services Layer

This layer consists of the services, services exposed by a arrangement derived from business organization functions.

For example –

Consider a Wellness Website which consists of

  1. Weight Tracker
  2. Blood Sugar Tracker
  3. Blood Pressure Tracker

Trackers display the respective data and date they are entered. Services layer consists of the services which gets the corresponding data from the Database–

  • Weight Tracker service
  • Claret Carbohydrate Tracker service
  • Blood Pressure Tracker service
  • Login Service

Process Layer

Procedure Layer consists the processes, drove of services which are office of a unmarried functionality.

The processes might be a part of user interface (for ex – A search engine), a office of an ETL tool (for getting data from the database).

The main focus in this layer will be in user interfaces and process.

The user interface of the weight tracker and its integration with the Database is the primary focus.

Below functions will exist of consideration

  1. Adding new data
  2. Editing existing data
  3. Creating new tracker
  4. Deleting data

Consumer Layer

This layer mainly comprises of user interfaces.

Learn SOA Testing

Based on the layer, the testing of an SOA application is distributed into three levels.

  1. Service level
  2. Interface level
  3. End to End level
  • Elevation Downward approach is used for Test Designing.
  • Bottom Upward approach is used for Test Execution.

Strategy for SOA Testing

Test Planning Approach,

  • The complete architecture of the application should exist understood past the SOA Testers.
  • The application needs to be broken downward into independent services (Service, which has their ain asking and response structure and does not depend on any other service to form response).
  • The application structure needs to exist reorganized into 3 components – Information, Services, and forepart-terminate applications.
  • All the components need to be advisedly analyzed, and business scenarios should be chalked out.
  • The business scenarios should be classified every bit common scenarios and application specific scenarios.
  • A Traceability Matrix should be prepared, and all test cases should be traced to business organisation scenarios.

Exam Execution Approach

  • Each service component should be tested.
  • Integration Testing of the service components should be done to validate the data flow through the services and information integrity.
  • System Testing of the complete model should be done to validate the data flow between front end-end awarding and database.
  • Performance Testing should be done for fine tuning and optimum functioning.

SOA Testing Methods

1) Business scenario driven data based testing,

  • Diverse business concern aspects related to the system should be analyzed.
  • Scenarios should be developed based on the integration of
  • Diverse Web services of the application
  • Web services and awarding.
  • Data set upward should exist washed based on the higher up scenarios.
  • Information gear up should be done and then as to comprehend finish to terminate scenarios every bit well.

2) Stubs

  • Dummy interfaces will be created to examination services.
  • Various inputs can exist provided through these interfaces, and the outputs can exist validated.
  • When an application uses an interface to an external service, which is not under exam (3rd party service), a stub can be created during Integration Testing.

three) Regression testing

  • Regression Testing on the application should be done when there are multiple releases then as to ensure the stability and availability of the systems.
  • A comprehensive regression test suite volition be created covering the services which form an of import role of the application.
  • This test suite tin be reused in multiple releases of the projection.

four) Service Level Testing

Service Level Testing includes testing the component for functionality, security, performance and interoperability.

Each and Every Service needs to be first tested independently.

5) Functional Testing

Functional Testing should be washed on each service to

  • Ensure that service delivers the correct response to each request.
  • Right errors are received for requests with Invalid data, bad data, etc.
  • Check for each request and response for each and every operation the service has to perform in run time.
  • Validate the mistake messages when an mistake occurs at the server, client or network level.
  • Validate that the responses received are in the right format.
  • Validate that the data received on the response corresponding to the data requested.

half dozen) Security Testing

Security testing of the web service is an important attribute during service level testing of the SOA application; this ensures the safety of the application.

The post-obit factors demand to be covered during testing:

  • Industry Standard defined past WS-Security testing should be abided past the Web Service.
  • Security measures should work flawlessly.
  • Encryption of data and Digital signatures on the documents
  • Hallmark and Authorization
  • SQL Injection, Malware, XSS, CSRF, other vulnerabilities are to be tested on the XML.
  • Deprival of Service attacks

7) Operation Testing

Performance Testing of the service needs to be done since the services are reusable and multiple applications might be using the same service.

The post-obit factors are considered during testing:

  • Performance and functionality of the service need to exist tested under heavy load.
  • The performance of the service needs to exist compared while working individually and within the application, it is coupled with.
  • Load testing of service should exist performed
  • to verify response time
  • to check for bottlenecks
  • to verify the utilization of CPU and memory
  • to predict scalability

8) Integration level testing

  • Service level testing ensures proper working of but the services individually, it does not guarantee the working of the coupled components.
  • Integration Testing is done focusing mainly on the interfaces.
  • This phase covers all the possible business organization scenarios.
  • The Non-Functional testing of the application should be done ane more fourth dimension in this phase. Security, compliance, and Operation Testing ensure the availability and stability of the system in all aspects.
  • The advice and network protocols should exist tested to validate the consistency of the information advice betwixt the services.

9) Stop to Finish testing

This phase ensures that the application confirms to the business organisation requirements both functionally and non-functionally.

The beneath items are ensured to be tested during the end to end testing

  • All services working as expected after integration
  • Exception handling
  • User Interface of the awarding
  • Proper data flow through all the components
  • Business concern process

Challenges in SOA testing

  • Lack of interfaces for Services
  • Testing process spans across multiple systems thus creating complex data needs
  • The awarding is a collection of diverse components which tends to alter. The need for Regression Testing is more than frequent.
  • Due to Multilayer architecture, information technology is difficult to isolate defects.
  • Since the service will be used in different interfaces, it is hard predicting load, hence making performance test planning cumbersome.
  • SOA is a collection of heterogeneous technologies. Testing of an SOA awarding requires people with different skill sets which in plow increment the planning and execution costs.
  • Since the application is an integration of multiple services, security testing has its ain share of woes. Validation of authentication and potency is pretty much difficult.

SOA Testing Tools

In that location are many SOA testing tools available in the market to help testers in testing SOA applications. Here are some of the popular SOA Testing Tools:

i) Lather UI

"SOAP UI" is an open source Functional testing tool for Services and API Testing.

  • Desktop application
  • Supports multiple protocols – SOAP, Residual, HTTP, JMS, AMF, JDBC
  • Spider web services can be developed, inspected and invoked.
  • Can as well use for load testing, Automation Testing, and security testing
  • Stubs tin be created past MockServices
  • Web Service requests and tests can exist generated automatically through its web service customer.
  • Take inbuilt reporting tools
  • Adult by SmartBear

2) iTKO LISA

"LISA" is a product suite which provides a functional testing solution for distributed systems similar SOA.

  • Tin also use for regression, integration, load and Performance Testing.
  • Adult by iTKO (CA Technologies)
  • Can exist used to design and execute tests.

iii) HP Service Test

"Service Examination" is a functional testing tool, which supports both UI and shared services testing

  • Both functional and functioning test of services can be washed by a unmarried script.
  • Integrated with HP QC.
  • The massive amount of service and information can be managed.
  • Supports interoperability testing by simulating JEE, AXIS, and DotNet customer environments.
  • Developed past HP.

four) Parasoft SOA Test

SOA Test is a testing and analysis tool suite developed for API and API applications testing.

  • Supports Spider web Services, Residuum, JSON, MQ, JMS, TIBCO, HTTP, XML technologies.
  • Functional, Unit, Integration, Regression, Security, Interoperability, Compliance and Performance Testing are possible.
  • Stubs can exist created using Parasoft Virtualize, which are intelligent than SOAP UI.
  • Developed past ParaSoft

SOA Testing Use Cases

Consider an e-commerce Website, which contains the beneath functions and Sub-functions:

Order Processing

Learn SOA Testing

PHASE 1

In the commencement phase of SOA testing i.eastward. Examination Strategy Stage, the application is broken into Services and business organization functions.

Let united states consider below are the Services in the awarding.

  • Create Order
  • Check Customer Condition
  • Modify Gild Status
  • Check Gild Status
  • Check Inventory

Business functions being the same as the functions of the Website.

Note: The test strategy document would contain the listing of the service and the functions which take to be tested.

Phase ii

Examination Planning stage. Test cases are written for each level.

  1. End to End level. The test cases are written for each business use case and flow.

    Below are the example of test cases

    • Create an lodge with the agile user.
    • Create an order with an inactive user.
    • Create an lodge with the available product with order quantity < bachelor quantity.
    • Create an order with the available product with order quantity > available quantity.
    • Create an order with multiple items
    • Cancel an society completely.
    • Cancel gild partially.
  2. Integration level. Exam cases are written for integration of database and user interface.

    Below are example test cases.

    • Create a new order with a single item. Verify that the order is created on the database.
    • Create a new guild with a single detail. Verify that the price calculated for the club is correct.
    • Create a new gild with a single item. Verify that the quantity of the available product is less by the order amount.
    • Verify that the condition of the club displayed on the UI is same every bit that on the database.
    • Cancel the social club and verify that the condition of the order is modified on the database.
    • For the kickoff time payment, verify that the payment details entered on the UI is saved on the database.
    • For returning payments, verify that the payment details on the database are displayed on the UI.
  3. Service level. Each service is tested for all the data weather condition.

Below are a few examples.

No. Order Details Lodge Status
1 Create Gild. No. of Items = one Quantity on social club < Quantity on database
ii Create Order. No. of Items > one Quantity on Social club < Quantity on database.
3 Create Guild No. of Items = one Quantity on Order > Quantity on database
4 Check Order status Status on database = Active
v Check Order status Condition on database = Shipped
half dozen Check Order status Status on database = Cancelled
vii Bank check Order status Order id = Invalid
8 Cheque production availability Quantity of product >0
9 Bank check product availability Quantity of product =0
10 Check product availability Product id = invalid

Stage iii – Test Execution

Examination Execution uses bottom-upward approach i.e. service level testing is done first, then Integration level and at last End to End testing.

ane) Service level

Let us consider that Soapui tool is considered for testing the application.

The WSDL and URL are browsed into the test window of SOAP.

The request for each service will be displayed on the request window.

By modifying the data equally per the service level test cases, requests are created for each test instance.

Test Instance Request Expected response

Create Society. No. of Items = 1Quantity on order < Quantity on db

<productid>x2</productid><quantity>2</quantity>

<orderid>o3251</orderid><message>Successful</bulletin>

Create Gild.No. of Items > 1Quantity on Society < Quantity on db

<productid>y1</productid><quantity>one</quantity><productid>y2</productid><quantity>3</quantity>

<orderid>o3251</orderid><message>Successful</message>

Create OrderNo. of Items = 1Quantity on Order > Quantity on db

<productid>x23</productid><quantity>200</quantity>

<orderid>nada</orderid><message>Unsuccessful</message>

Check Guild statusStatus on database = Agile

<orderid>o9876</orderid>

<status>Active</active><message>Successful</message>

Check Order statusStatus on database = Shipped

<orderid>o9656</orderid>

<status>Shipped</active><bulletin>Successful</message>

Bank check Society statusOrder id = Invalid

<orderid>y5686</orderid>

<condition>nothing</agile><message>Unsuccessful</message>

Check production availabilityQuantity of product >0

<productid>d34</productid>

<quantity>34</quantity><bachelor>yes</available><bulletin>Successful</message>

Check product availabilityQuantity of product =0

<productid>y34</productid>

<quantity>0</quantity><available>no</available><message>Successful</bulletin>

Check product availabilityProduct id = invalid

<productid>sder</productid>

<message>Unsuccessful</message>

2) Integration Level

The integration level test cases are executed on the User interface and database.

  • Create an order with a single item –
  • A user opens the website.
  • Goes to identify an social club.
  • Selects a valid product and quantity and saves the gild.
  • A message saying the Social club is placed successfully should be displayed.
  • A user opens database and checks if the details of the order are same as that entered on the website.
three) Finish to End level

The concern flows and apply cases are executed on the User interface.

  • Create an order with multiple items –
  • A user opens a website.
  • Goes to place an lodge.
  • Enquires virtually a valid production and quantity adds them to cart.
  • Other valid products are added with valid quantities and the order is saved. Payment is washed through a new payment method and society is placed.
  • A message saying "Order placed successfully" should exist displayed.
  • A tester should validate that the whole flow is done without skewing of information.

Conclusion:

By sketching the correct strategy for testing, resources, tools, and compliance to provide expert service, SOA testing can deliver completely and perfectly tested application.

Source: https://www.guru99.com/learn-soa-testing.html

Posted by: olivedentry57.blogspot.com

0 Response to "How To Create Mock Service In Parasoft Soa"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel