SAOPUI Basic navigation PPT.ppt

download SAOPUI Basic navigation PPT.ppt

of 23

Transcript of SAOPUI Basic navigation PPT.ppt

  • Creating Project in SOAPUI Tool.How To Add WSDL to project.Creating Test Suit ,Test Cases , And Test Steps.Adding Assertions.How to Add Properties(Global And Local)Accessing The Data from the Properties to test step.How to Create Properties Using Groovy Script

  • Step 1 in the SOAPUI main window Right click on projects and select New SOAPUI project.

  • Create A new SOAPUI Project Dialogue Box Appears.Enter The Project Name Ex: Currency converterAnd Press Ok

  • Right Click on the project name which u have created in the previous step and click on Add WSDL To the project.Add WSDL Dialogue box appears. Paste the WSDL URL in the WSDL Location FieldCheck The create sample request for all operations check box And Press ok . WSDL will be validated and added to current project With a sample request.

  • Right Click on the ServiceSelect the generate test suit option.

  • Generate Test suit Dialogue appears click ok.

  • Enter the test suit name and press okTest suit is created with a single test stepTo create more test requests right click on the test step and select add step test request.Give the teststep name press ok

  • Give the test step name press ok

  • And select the operation to which you want to add this requestGive the name for the test case and Uncheck All default and click ok.

  • Add request to test case dialogue appears Give a name To the test case and uncheck all the defaults and click ok

  • Schema ComplianceXPath MatchContainsXQuery MatchNot ContainsScript AssertionSOAP FaultWS-Security StatusNot SOAP FaultWS-Addressing Response AssertionSOAP ResponseWS-Addressing Request AssertionResponse SLA

  • Schema Compliance - validates the response message against the definition in the WSDL and contained XML SchemaSOAP Response - checks that the response is a valid SOAP ResponseContains - checks for the existence of a specified stringNot Contains - checks for the non-existence of a specified string Reponse SLA - check the response time against a specified value XPath Match - compares the result of an XPath expression to an expected valueXQuery match - compares the result on an XQuery expression to an expected valueScript - runs an arbitrary script that can be used to validate the received message as desiredSOAP Fault - checks that the response is a SOAP Fault (The SOAP Fault element holds errors and status information for a SOAP message. E.g.; Namespace Mismatch)Not SOAP Fault - checks that the response is not a SOAP Fault

  • WS-Security Status - validates the WS-Security headers and tokens in the responseWS-Addressing Response - validates the WS-Addressing Headers in the responseXpath is a language for finding information in an XML document.Xpath Match is an assertion in soapUI.It compares the result of an XPath expression to an expected value

  • Step 1:Open test step Click on the add assertion buttonStep 2:Select the assertion Contains from the dropdown list and click ok

  • Step 3:Enter the Content you are expecting in the response and click ok

  • Step 1:Right click on the Test case select add test step select Properties test step.

  • Step 2:Give a name and click ok the properties dialogue appears.

  • Click on the Add property button and a unique property name press ok

  • Give Value to the property in the value Colum.

  • Go to the Test request Right Click on the field navigate Get data->properties->Property

  • Double Click on the Test suit In test suit Editor Window Click On the Properties TabClick On the Add Properties Button Enter The Global property name and value

  • Create a text file for the properties and save it.Add Groovy Script test request.Write the groovy script in the groovy script editorClick on run button

  • Thank You