SlideShare a Scribd company logo
Vasilis PETROU | Test Automation Lead
Testing Web Services
with an Object-Oriented way
15th Thessaloniki Software Testing and QA Meetup
Vasilis Petrou
“Knowledge is only real when shared”
֍test automation lead at INTRASOFT International;
֍more than 11 years experience in full-stack
development and more than 4 years in test
automation;
֍co-organizer of Software Testing & QA Meetup
Thessaloniki Greece;
֍volunteer organizer of lectures about Software
Testing & Test Automation in Universities &
Institutions.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
Thessaloniki Software Testing & QA Meetup
Google Docs For Proposals
https://tinyurl.com/y6nm4l9w
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
Thessaloniki Software Testing & QA Meetup
Slack Channel
https://tinyurl.com/y4gw24p2
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
headcount
2.000+ professionals
20+ nationalities
500+ organizations worldwide
have chosen our services
eu institutions
public sector
enterprise solutions
47% university graduates
24% msc/phd holders
key player in
e.u. institutions and
agencies for 20+ years
established in 1996 in
luxembourg, operations
in 13 countries
outstanding record
in over 70+ countries
around the globe
a leading european IT solutions
& services company
more than 25% growth
in revenue over
the past 2 years
#WeAreIntrasoft
 independent Testing Team of
INTRASOFT International
 one of the biggest Testing
Centers in Greece
 more than 20 test engineers
do automation
 large number of
implementations on the
testing types included in the
tree
Functional Performance
GUI
Data
Migration
Non-
Functional
API
Usability
Configuration
StressLoad
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
Azure
Devops
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
to test web services
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
we will use
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
why SoapUI?
 user-friendly GUI
 easy for functional testing
 automation with Apache Groovy
 data-driven testing
 assertions
 it’s free!!!
SoapUI Open Source is a free for Commercial Use
Software under the terms of European Union
Public License (EUPL V.1.1).
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
what are web services?
web service is a software system designed to support
machine-to-machine interaction over a network.
- W3C -
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
what are the types of web services?
SOAP & REST Web Services
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
what are the SOAP Web Services?
Simple Object Access Protocol (SOAP) is an XML-based protocol.
the biggest advantage of using the SOAP Web Service is its own security.
SOAP provides an envelope to send a web services messages over the Internet, using the HTTP protocol.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
what are the REST Web Services?
Representational State Transfer (REST) is a style of software architecture
for creating web services using predefined operations GET POST PUT DELETE.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
let’s start practice
to automate web service tests
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
but first, what do we need?
of course, a web service
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
prepare to build a Web Service Application
step 1
assuming that we work on a Windows OS machine, next steps
should be followed to build an indicative Web Service Application
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download and Install
JAVA 8
https://www.oracle.com/technet
work/java/javase/downloads/jdk8
-downloads-2133151.html
step 1. prepare to build a Web Service Application (1 of 5)
* don’t forget to set JAVA_HOME environment variable
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download and Install
Maven
http://maven.apache.org/downlo
ad.cgi
* don’t forget to set MAVEN_HOME environment variable
step 1. prepare to build a Web Service Application (2 of 5)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download and Install
Docker for Windows
https://docs.docker.com/docker-for-
windows/install/
* don’t forget to update settings and share your drive.
step 1. prepare to build a Web Service Application (3 of 5)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download and Install
GIT for Windows
https://gitforwindows.org/
step 1. prepare to build a Web Service Application (4 of 5)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download
an indicative Web
Service Application
from my GIT Repo
https://github.com/vpetrou/spring-boot-
soap-ws
* the Web Service Application is written in JAVA Spring Boot with MySQL DB
step 1. prepare to build a Web Service Application (5 of 5)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
build the indicative Web Service Application
step 2
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
right click on the
folder with the
indicative Web
Service Application
and select
GIT Bash here
step 2. build the indicative Web Service Application (1 of 3)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
from the Git Bash
window, execute the
command:
./install.sh
step 2. build the indicative Web Service Application (2 of 3)
and wait until the
application is started. * ports 8080 and 3306 are used by the Docker Containers
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
visit URL:
http://localhost:8080/soapws/contacts.wsdl
to verify that Web Service is
Up & Running.
the Web Services Description Language
(WSDL) is an XML-based interface
description language that is used for
describing the functionality offered by a web
service.
step 2. build the indicative Web Service Application (3 of 3)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
analyze the Web Service under Test
step 3
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
the name of the web service is ContactsPortService
step 3. analyze the Web Service under Test (1 of 5)
this service contains CRUD service operations
* definition of CRUD: Create Read Update Delete
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
available Service Operations of ContactsPortService:
step 3. analyze the Web Service under Test (2 of 5)
 addContact: to add a new contact;
 updateContact: to update a contact;
 deleteContact: to delete a contact;
 getAllContacts: to get a list of all contacts;
 getContactById: to get a contact by Id;
 getContactByName: to get all contacts that contain all or part of given name.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
columns of table Contact:
step 3. analyze the Web Service under Test (3 of 5)
 contactId: numeric(1..5), Key, Auto Increment;
 name: Not Null, Alphanumeric(1..30);
 nickName: Alphanumeric(8), Pattern (4 letters and 4 numbers)
 category: Alphanumeric(0..30)
 phone: Numeric(0..14)
 email: Alphanumeric(0..30), Email Pattern (…@...)
 city: Alphanumeric(0..30)
 country: Alphanumeric(0..30)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
proof of concept (PoC):
step 3. analyze the Web Service under Test (4 of 5)
We will create some indicative test cases for the “addContact” service operation.
Each Test Case will contain a groovy step to generate a random “nickName” with
the accepted pattern “4 letters and 4 numbers”.
After the implementation, a request for change will be handled to check the
maintenance effort. This request for change will be related with the column
“nickName” where the pattern changes to “4 letters and 6 numbers”.
The maintenance effort between the 2 different implementation methodologies in
SoapUI will be compared.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
indicative Test Cases for the test suite TS-SRV-AddContacts :
step 3. analyze the Web Service under Test (5 of 5)
 TC-SRV-AddContacts-P-001: Tests the addition of a contact where all the fields are inserted
with valid value.
 TC-SRV-AddContacts-N-001: Tests the addition of a contact where all the fields are inserted
with valid value except field ‘email’ which has invalid value.
 TC-SRV-AddContacts-N-002: Tests the addition of a contact where all the fields are inserted
with valid value except field ‘phone’ which has invalid value.
 TC-SRV-AddContacts-N-003: Tests the addition of a contact where all the fields are inserted
with valid value except field ‘nickName’ which has invalid value.
* naming convention of Test Case ID: TC = Test Case, SRV = Services, AddContacts = Service Operation, P = Positive or N = Negative, 001 = Serial Number
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
prepare to build Web Service Test Scripts
step 4
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
download and Install
SoapUI Open Source
https://www.soapui.org/downloads/soa
pui.html
step 4. prepare to build Web Service Test Scripts
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
build Web Service Test Scripts via SoapUI
with the common way
step 5
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
open SoapUI Open Source
step 5. build Web Service Test Scripts via SoapUI with the common way (1 of 16)
and start a new project (e.g. SEETest-SrvTests) selecting “New SOAP Project”
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
before proceeding with test cases, select “Save Project”
* it is not mandatory to save the project at the beginning. It is
just a suggestion in order not to forget to save it before exiting.
step 5. build Web Service Test Scripts via SoapUI with the common way (2 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
right click on SoapUI Project and
select option “New TestSuite”
then specify the name “TS-SRV-
AddContacts” for the new test
suite.
step 5. build Web Service Test Scripts via SoapUI with the common way (3 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
right click on Test Suite “TS-SRV-
AddContacts” and select option
“New TestCase”
then specify the name “TC-SRV-
AddContacts-P-001” for the new
test case.
step 5. build Web Service Test Scripts via SoapUI with the common way (4 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
right click on Test Case “TC-SRV-
AddContacts-P-001” and select
option “Add Step” and “Soap
Request”
then specify the name
“AddContactWithAllFieldsValid”
for the new step.
step 5. build Web Service Test Scripts via SoapUI with the common way (5 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
specify additional options for the
new step (e.g. “Add SOAP Response
Assertion” to be checked).
specify the service operation
“addContact” to invoke for the request.
step 5. build Web Service Test Scripts via SoapUI with the common way (6 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
step 5. build Web Service Test Scripts via SoapUI with the common way (7 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
right click on Test Case “TC-SRV-
AddContacts-P-001” and select
option “Add Step” and “Groovy
Script”
then specify the name
“GenerateNickName” for the
new step.
create a groovy step to generate a nickname
step 5. build Web Service Test Scripts via SoapUI with the common way (8 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
drag ‘n drop step
‘GenerateNickName’ to be first
in the list of steps of test case
“TC-SRV-AddContacts-P-001”
step 5. build Web Service Test Scripts via SoapUI with the common way (9 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
step ‘GenerateNickName’ returns a random string with 4
letters and 4 numbers:
* this groovy step is indicative, just for demonstration reasons.
step 5. build Web Service Test Scripts via SoapUI with the common way (10 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
now, we will insert values in all fields of step
‘AddContactWithAllFieldsValid’:
* ${GenerateNickName#result} returns the result of groovy step GenerateNickName
step 5. build Web Service Test Scripts via SoapUI with the common way (11 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
running step ‘AddContactWithAllFieldsValid’ we will see a
response with SUCCESS status code:
step 5. build Web Service Test Scripts via SoapUI with the common way (12 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
add an assertion to step ‘AddContactWithAllFieldsValid’ to
verify that response contains the word “SUCCESS”:
step 5. build Web Service Test Scripts via SoapUI with the common way (13 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
finally to be able to run and re-run the same test case insert the appropriate
steps to get the new generated contact ID and remove the contact.
step 5. build Web Service Test Scripts via SoapUI with the common way (14 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
after we get the new generated contact ID via a Groovy step, we can
use it in a next Soap Request step to remove the Contact.
step 5. build Web Service Test Scripts via SoapUI with the common way (15 of 16)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
repeat above steps (or clone) to implement the rest test cases.
* test case TC-SRV-AddContacts-N-003 will be the only one that will not contain groovy step “GenerateNickName”.
step 5. build Web Service Test Scripts via SoapUI with the common way (16 of 16)
A full run proves that tests work properly.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
build Web Service Test Scripts via SoapUI
with the object oriented way
step 6
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
open SoapUI Open Source
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (1 of 8)
and start a new project (e.g. SEETest-SrvTestsV2) selecting “New SOAP Project”
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
to avoid the re-creation of test cases just right click and select “Clone
TestSuite” to clone test suite of SEETest-SrvTests to SEETest-SrvTestsV2
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (2 of 8)
before proceeding with test cases,
select “Save Project”
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
step “GenerateNickName” of test cases
• TC-SRV-AddContacts-P-001
• TC-SRV-AddContacts-N-001
• TC-SRV-AddContacts-N-002
will be updated with the use of
External Groovy Script
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (3 of 8)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
why to use External Groovy Script?
implementation of repeated steps will be handled from a single point.
so, if an update affects these steps, the effort to update them is almost
nothing in relation to the effort it takes to update all the affected steps
one by one.
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (4 of 8)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
in the same folder with the SoapUI project (SEETest-SrvTestsV2-
soapui-project.xml) create a file with name “seetest.groovy”
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (5 of 8)
copy-paste the content of Groovy Step “GenerateNickName”
to External Groovy Script “seetest.groovy”
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (6 of 8)
method “getNickname()”
returns an auto-generated
nickname based on
pattern (4 letters + 4
numbers)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
in SoapUI Project update groovy Step “GenerateNickName” (for all test
cases) to call method “getNickname()” from the External Groovy Script
“seetest.groovy”
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (7 of 8)
* above implementation is based on GroovyScriptEngine: http://docs.groovy-lang.org/latest/html/api/groovy/util/GroovyScriptEngine.html
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
the implementation of method “getNickname()” is now out of SoapUI
which means that any change about how the nickname should be, will
affect only External Groovy Script “seetest.groovy”.
step 6. build Web Service Test Scripts via SoapUI with the object oriented way (8 of 8)
a full run proves that tests work properly.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
update Web Service Test Scripts
based on Request for Change (RfC)
step 7
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
so, in a next release of the application, our customer decided to
request a change regarding the nickname.
the pattern must change
from “4 letters and 4 numbers”
to “4 letters and 6 numbers”.
step 7. update Web Service Test Scripts based on Request for Change (RfC)(1 of 4)
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
based on the 2 different implementation methodologies in SoapUI
(step 5 & step 6), below is displayed a table of affections:
step 7. update Web Service Test Scripts based on Request for Change (RfC)(2 of 4)
Common Methodology Object Oriented Methodology
Affected Test Steps in SoapUI 3 0
Affected External Groovy Scripts 0 1
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
based on common methodology each “GenerateNickName”
must be updated in SoapUI.
step 7. update Web Service Test Scripts based on Request for Change (RfC)(3 of 4)
in this demo project effort seems to be low, but when we are talking about hundreds of
affected test cases and when the update is not such simple allowing us to make a simple
Search-Replace in the SoapUI Project XML file, then maintenance is a real bottleneck.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
based on object oriented methodology nothing should be
updated in SoapUI. Only method “getNickname()” of the external
groovy script “seetest.groovy” must be updated properly.
step 7. update Web Service Test Scripts based on Request for Change (RfC)(4 of 4)
the fact that the effort relates to only one point outside SoapUI makes not only maintenance
easier in terms of the needed actions but also in terms of guidelines. When we deliver a
SoapUI project and something goes wrong it is easier to suggest workarounds by simply
editing content of groovy files than giving workarounds with actions inside SoapUI steps.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
in conclusion (1 of 3)
there is a minor disadvantage of using External Groovy Scripts:
 when a part of external groovy method has failure, we must work with 2 different environments.
Meaning that the script can be opened e.g. with Notepad++ (it cannot be opened via SoapUI directly to
quickly edit the script and proceed.
tip: we usually work with external groovy files via IntelliJ Community Edition having installed the Groovy SDK. http://groovy-lang.org/download.html
there we can run and debug groovy scripts and find easier all the needed “imports”.
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
in conclusion (2 of 3)
the advantage of the easier maintenance and the external handling is such significant
that makes the selection of this methodology a real need.
and after this easier maintenance, we feel like…
MVPs
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
in conclusion (3 of 3)
of course, there are applications, where the number of test cases is not large, or the
resources (test engineers) have not the necessary skills.
there is no right or wrong
based on the project’s needs…
the decision is yours to make
where to find the SoapUI Projects?
 GitHub:
https://github.com/vpetrou/srv-tests-soapui
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
where to find me?
 my GitHub:
https://github.com/vpetrou
 my LinkedIn Profile:
https://www.linkedin.com/in/vasilis-petrou-09a785a3/
 my Emails:
vasilios.petrou@intrasoft-intl.com
petrou82@gmail.com
vasilis.petrou@outlook.com.gr
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
thank you
questions?
15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International

More Related Content

PDF
Selenium and Open Source Advanced Testing
PPTX
OIDF Virtual Workshop -- 5/21/2020 -- OpenID Certification Program Update
PPTX
Make the Shift from Manual to Automation with Open Source
PDF
5 Steps to Detecting Issues Earlier in Your Release Cycles
PPTX
Selenium Automation Like You’ve Never Seen!
PPT
Journey To Excellence
PDF
So You Just Inherited a $Legacy Application… NomadPHP July 2016
PDF
Test automation design patterns
Selenium and Open Source Advanced Testing
OIDF Virtual Workshop -- 5/21/2020 -- OpenID Certification Program Update
Make the Shift from Manual to Automation with Open Source
5 Steps to Detecting Issues Earlier in Your Release Cycles
Selenium Automation Like You’ve Never Seen!
Journey To Excellence
So You Just Inherited a $Legacy Application… NomadPHP July 2016
Test automation design patterns

What's hot (12)

PPT
Ranorex - Highlights
PPT
UI Interactions Testing with FlexMonkey
PDF
Ranorex Studio - Introduction, Features & Limitations - Mobile Test Automati...
PPTX
Continuous Testing
PDF
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
PPTX
Intro to Automation Using Perfecto's CQ Lab
PPTX
Launch Better Apps, Faster - Perfecto & Orasi Joint Webinar Sldies
ODP
API Testing With Katalon Studio
PPTX
The Right Tool for the Right Project
PDF
10 Best Mobile Test Automation Tools Used by Experts | What Automation Tools ...
PDF
So You Just Inherited a $Legacy Application...
PPT
Enterprise Ready Test Execution Platform for Mobile Apps
Ranorex - Highlights
UI Interactions Testing with FlexMonkey
Ranorex Studio - Introduction, Features & Limitations - Mobile Test Automati...
Continuous Testing
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
Intro to Automation Using Perfecto's CQ Lab
Launch Better Apps, Faster - Perfecto & Orasi Joint Webinar Sldies
API Testing With Katalon Studio
The Right Tool for the Right Project
10 Best Mobile Test Automation Tools Used by Experts | What Automation Tools ...
So You Just Inherited a $Legacy Application...
Enterprise Ready Test Execution Platform for Mobile Apps
Ad

Similar to 15th meetup thessaloniki_softwaretestingqa_vasilispetrou_testingwebserviceinobjectorientedway (20)

PPTX
Testing API's: Tools & Tips & Tricks (Oh My!)
PPTX
Introduction to SoapUI day 4-5
PPTX
Learn SoapUI
PPTX
WebServices using Soap
PPTX
SoapUi using WebServices
PPTX
WebServices using Soapui
PPTX
Testing soapui
PPTX
Testing soapui
 
PPT
Introduction of WebServices
DOC
Soap ui documentation
PPTX
Web services testing
PPTX
WebServices
PDF
White paper ready api
PPTX
SOA Testing
PPTX
Web Services.pptx
PPTX
WebServices Basic Introduction
PDF
Testing RESTful Web Services
PDF
Webservices Testing PPT.pdf
PPTX
Soap UI and postman
PPTX
SOAPUI Test Design & Utilities
Testing API's: Tools & Tips & Tricks (Oh My!)
Introduction to SoapUI day 4-5
Learn SoapUI
WebServices using Soap
SoapUi using WebServices
WebServices using Soapui
Testing soapui
Testing soapui
 
Introduction of WebServices
Soap ui documentation
Web services testing
WebServices
White paper ready api
SOA Testing
Web Services.pptx
WebServices Basic Introduction
Testing RESTful Web Services
Webservices Testing PPT.pdf
Soap UI and postman
SOAPUI Test Design & Utilities
Ad

Recently uploaded (20)

PPTX
Computer Software and OS of computer science of grade 11.pptx
PDF
top salesforce developer skills in 2025.pdf
PDF
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PPTX
Introduction to Artificial Intelligence
PDF
Design an Analysis of Algorithms I-SECS-1021-03
PDF
Upgrade and Innovation Strategies for SAP ERP Customers
PDF
Softaken Excel to vCard Converter Software.pdf
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
PDF
Designing Intelligence for the Shop Floor.pdf
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
Embracing Complexity in Serverless! GOTO Serverless Bengaluru
PPTX
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PPTX
VVF-Customer-Presentation2025-Ver1.9.pptx
PPTX
CHAPTER 2 - PM Management and IT Context
PPTX
assetexplorer- product-overview - presentation
PDF
System and Network Administration Chapter 2
Computer Software and OS of computer science of grade 11.pptx
top salesforce developer skills in 2025.pdf
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
Navsoft: AI-Powered Business Solutions & Custom Software Development
Introduction to Artificial Intelligence
Design an Analysis of Algorithms I-SECS-1021-03
Upgrade and Innovation Strategies for SAP ERP Customers
Softaken Excel to vCard Converter Software.pdf
How to Migrate SBCGlobal Email to Yahoo Easily
Which alternative to Crystal Reports is best for small or large businesses.pdf
Designing Intelligence for the Shop Floor.pdf
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Embracing Complexity in Serverless! GOTO Serverless Bengaluru
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
2025 Textile ERP Trends: SAP, Odoo & Oracle
Internet Downloader Manager (IDM) Crack 6.42 Build 41
VVF-Customer-Presentation2025-Ver1.9.pptx
CHAPTER 2 - PM Management and IT Context
assetexplorer- product-overview - presentation
System and Network Administration Chapter 2

15th meetup thessaloniki_softwaretestingqa_vasilispetrou_testingwebserviceinobjectorientedway

  • 1. Vasilis PETROU | Test Automation Lead Testing Web Services with an Object-Oriented way 15th Thessaloniki Software Testing and QA Meetup
  • 2. Vasilis Petrou “Knowledge is only real when shared” ֍test automation lead at INTRASOFT International; ֍more than 11 years experience in full-stack development and more than 4 years in test automation; ֍co-organizer of Software Testing & QA Meetup Thessaloniki Greece; ֍volunteer organizer of lectures about Software Testing & Test Automation in Universities & Institutions. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
  • 3. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International Thessaloniki Software Testing & QA Meetup Google Docs For Proposals https://tinyurl.com/y6nm4l9w
  • 4. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International Thessaloniki Software Testing & QA Meetup Slack Channel https://tinyurl.com/y4gw24p2
  • 5. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International headcount 2.000+ professionals 20+ nationalities 500+ organizations worldwide have chosen our services eu institutions public sector enterprise solutions 47% university graduates 24% msc/phd holders key player in e.u. institutions and agencies for 20+ years established in 1996 in luxembourg, operations in 13 countries outstanding record in over 70+ countries around the globe a leading european IT solutions & services company more than 25% growth in revenue over the past 2 years #WeAreIntrasoft
  • 6.  independent Testing Team of INTRASOFT International  one of the biggest Testing Centers in Greece  more than 20 test engineers do automation  large number of implementations on the testing types included in the tree Functional Performance GUI Data Migration Non- Functional API Usability Configuration StressLoad 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
  • 7. Azure Devops 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
  • 8. to test web services 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International we will use
  • 9. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International why SoapUI?  user-friendly GUI  easy for functional testing  automation with Apache Groovy  data-driven testing  assertions  it’s free!!! SoapUI Open Source is a free for Commercial Use Software under the terms of European Union Public License (EUPL V.1.1).
  • 10. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International what are web services? web service is a software system designed to support machine-to-machine interaction over a network. - W3C -
  • 11. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International what are the types of web services? SOAP & REST Web Services
  • 12. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International what are the SOAP Web Services? Simple Object Access Protocol (SOAP) is an XML-based protocol. the biggest advantage of using the SOAP Web Service is its own security. SOAP provides an envelope to send a web services messages over the Internet, using the HTTP protocol.
  • 13. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International what are the REST Web Services? Representational State Transfer (REST) is a style of software architecture for creating web services using predefined operations GET POST PUT DELETE.
  • 14. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International let’s start practice to automate web service tests
  • 15. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International but first, what do we need? of course, a web service
  • 16. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International prepare to build a Web Service Application step 1 assuming that we work on a Windows OS machine, next steps should be followed to build an indicative Web Service Application
  • 17. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download and Install JAVA 8 https://www.oracle.com/technet work/java/javase/downloads/jdk8 -downloads-2133151.html step 1. prepare to build a Web Service Application (1 of 5) * don’t forget to set JAVA_HOME environment variable
  • 18. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download and Install Maven http://maven.apache.org/downlo ad.cgi * don’t forget to set MAVEN_HOME environment variable step 1. prepare to build a Web Service Application (2 of 5)
  • 19. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download and Install Docker for Windows https://docs.docker.com/docker-for- windows/install/ * don’t forget to update settings and share your drive. step 1. prepare to build a Web Service Application (3 of 5)
  • 20. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download and Install GIT for Windows https://gitforwindows.org/ step 1. prepare to build a Web Service Application (4 of 5)
  • 21. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download an indicative Web Service Application from my GIT Repo https://github.com/vpetrou/spring-boot- soap-ws * the Web Service Application is written in JAVA Spring Boot with MySQL DB step 1. prepare to build a Web Service Application (5 of 5)
  • 22. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International build the indicative Web Service Application step 2
  • 23. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International right click on the folder with the indicative Web Service Application and select GIT Bash here step 2. build the indicative Web Service Application (1 of 3)
  • 24. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International from the Git Bash window, execute the command: ./install.sh step 2. build the indicative Web Service Application (2 of 3) and wait until the application is started. * ports 8080 and 3306 are used by the Docker Containers
  • 25. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International visit URL: http://localhost:8080/soapws/contacts.wsdl to verify that Web Service is Up & Running. the Web Services Description Language (WSDL) is an XML-based interface description language that is used for describing the functionality offered by a web service. step 2. build the indicative Web Service Application (3 of 3)
  • 26. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International analyze the Web Service under Test step 3
  • 27. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International the name of the web service is ContactsPortService step 3. analyze the Web Service under Test (1 of 5) this service contains CRUD service operations * definition of CRUD: Create Read Update Delete
  • 28. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International available Service Operations of ContactsPortService: step 3. analyze the Web Service under Test (2 of 5)  addContact: to add a new contact;  updateContact: to update a contact;  deleteContact: to delete a contact;  getAllContacts: to get a list of all contacts;  getContactById: to get a contact by Id;  getContactByName: to get all contacts that contain all or part of given name.
  • 29. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International columns of table Contact: step 3. analyze the Web Service under Test (3 of 5)  contactId: numeric(1..5), Key, Auto Increment;  name: Not Null, Alphanumeric(1..30);  nickName: Alphanumeric(8), Pattern (4 letters and 4 numbers)  category: Alphanumeric(0..30)  phone: Numeric(0..14)  email: Alphanumeric(0..30), Email Pattern (…@...)  city: Alphanumeric(0..30)  country: Alphanumeric(0..30)
  • 30. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International proof of concept (PoC): step 3. analyze the Web Service under Test (4 of 5) We will create some indicative test cases for the “addContact” service operation. Each Test Case will contain a groovy step to generate a random “nickName” with the accepted pattern “4 letters and 4 numbers”. After the implementation, a request for change will be handled to check the maintenance effort. This request for change will be related with the column “nickName” where the pattern changes to “4 letters and 6 numbers”. The maintenance effort between the 2 different implementation methodologies in SoapUI will be compared.
  • 31. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International indicative Test Cases for the test suite TS-SRV-AddContacts : step 3. analyze the Web Service under Test (5 of 5)  TC-SRV-AddContacts-P-001: Tests the addition of a contact where all the fields are inserted with valid value.  TC-SRV-AddContacts-N-001: Tests the addition of a contact where all the fields are inserted with valid value except field ‘email’ which has invalid value.  TC-SRV-AddContacts-N-002: Tests the addition of a contact where all the fields are inserted with valid value except field ‘phone’ which has invalid value.  TC-SRV-AddContacts-N-003: Tests the addition of a contact where all the fields are inserted with valid value except field ‘nickName’ which has invalid value. * naming convention of Test Case ID: TC = Test Case, SRV = Services, AddContacts = Service Operation, P = Positive or N = Negative, 001 = Serial Number
  • 32. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International prepare to build Web Service Test Scripts step 4
  • 33. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International download and Install SoapUI Open Source https://www.soapui.org/downloads/soa pui.html step 4. prepare to build Web Service Test Scripts
  • 34. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International build Web Service Test Scripts via SoapUI with the common way step 5
  • 35. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International open SoapUI Open Source step 5. build Web Service Test Scripts via SoapUI with the common way (1 of 16) and start a new project (e.g. SEETest-SrvTests) selecting “New SOAP Project”
  • 36. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International before proceeding with test cases, select “Save Project” * it is not mandatory to save the project at the beginning. It is just a suggestion in order not to forget to save it before exiting. step 5. build Web Service Test Scripts via SoapUI with the common way (2 of 16)
  • 37. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International right click on SoapUI Project and select option “New TestSuite” then specify the name “TS-SRV- AddContacts” for the new test suite. step 5. build Web Service Test Scripts via SoapUI with the common way (3 of 16)
  • 38. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International right click on Test Suite “TS-SRV- AddContacts” and select option “New TestCase” then specify the name “TC-SRV- AddContacts-P-001” for the new test case. step 5. build Web Service Test Scripts via SoapUI with the common way (4 of 16)
  • 39. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International right click on Test Case “TC-SRV- AddContacts-P-001” and select option “Add Step” and “Soap Request” then specify the name “AddContactWithAllFieldsValid” for the new step. step 5. build Web Service Test Scripts via SoapUI with the common way (5 of 16)
  • 40. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International specify additional options for the new step (e.g. “Add SOAP Response Assertion” to be checked). specify the service operation “addContact” to invoke for the request. step 5. build Web Service Test Scripts via SoapUI with the common way (6 of 16)
  • 41. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International step 5. build Web Service Test Scripts via SoapUI with the common way (7 of 16)
  • 42. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International right click on Test Case “TC-SRV- AddContacts-P-001” and select option “Add Step” and “Groovy Script” then specify the name “GenerateNickName” for the new step. create a groovy step to generate a nickname step 5. build Web Service Test Scripts via SoapUI with the common way (8 of 16)
  • 43. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International drag ‘n drop step ‘GenerateNickName’ to be first in the list of steps of test case “TC-SRV-AddContacts-P-001” step 5. build Web Service Test Scripts via SoapUI with the common way (9 of 16)
  • 44. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International step ‘GenerateNickName’ returns a random string with 4 letters and 4 numbers: * this groovy step is indicative, just for demonstration reasons. step 5. build Web Service Test Scripts via SoapUI with the common way (10 of 16)
  • 45. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International now, we will insert values in all fields of step ‘AddContactWithAllFieldsValid’: * ${GenerateNickName#result} returns the result of groovy step GenerateNickName step 5. build Web Service Test Scripts via SoapUI with the common way (11 of 16)
  • 46. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International running step ‘AddContactWithAllFieldsValid’ we will see a response with SUCCESS status code: step 5. build Web Service Test Scripts via SoapUI with the common way (12 of 16)
  • 47. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International add an assertion to step ‘AddContactWithAllFieldsValid’ to verify that response contains the word “SUCCESS”: step 5. build Web Service Test Scripts via SoapUI with the common way (13 of 16)
  • 48. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International finally to be able to run and re-run the same test case insert the appropriate steps to get the new generated contact ID and remove the contact. step 5. build Web Service Test Scripts via SoapUI with the common way (14 of 16)
  • 49. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International after we get the new generated contact ID via a Groovy step, we can use it in a next Soap Request step to remove the Contact. step 5. build Web Service Test Scripts via SoapUI with the common way (15 of 16)
  • 50. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International repeat above steps (or clone) to implement the rest test cases. * test case TC-SRV-AddContacts-N-003 will be the only one that will not contain groovy step “GenerateNickName”. step 5. build Web Service Test Scripts via SoapUI with the common way (16 of 16) A full run proves that tests work properly.
  • 51. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International build Web Service Test Scripts via SoapUI with the object oriented way step 6
  • 52. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International open SoapUI Open Source step 6. build Web Service Test Scripts via SoapUI with the object oriented way (1 of 8) and start a new project (e.g. SEETest-SrvTestsV2) selecting “New SOAP Project”
  • 53. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International to avoid the re-creation of test cases just right click and select “Clone TestSuite” to clone test suite of SEETest-SrvTests to SEETest-SrvTestsV2 step 6. build Web Service Test Scripts via SoapUI with the object oriented way (2 of 8) before proceeding with test cases, select “Save Project”
  • 54. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International step “GenerateNickName” of test cases • TC-SRV-AddContacts-P-001 • TC-SRV-AddContacts-N-001 • TC-SRV-AddContacts-N-002 will be updated with the use of External Groovy Script step 6. build Web Service Test Scripts via SoapUI with the object oriented way (3 of 8)
  • 55. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International why to use External Groovy Script? implementation of repeated steps will be handled from a single point. so, if an update affects these steps, the effort to update them is almost nothing in relation to the effort it takes to update all the affected steps one by one. step 6. build Web Service Test Scripts via SoapUI with the object oriented way (4 of 8)
  • 56. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International in the same folder with the SoapUI project (SEETest-SrvTestsV2- soapui-project.xml) create a file with name “seetest.groovy” step 6. build Web Service Test Scripts via SoapUI with the object oriented way (5 of 8) copy-paste the content of Groovy Step “GenerateNickName” to External Groovy Script “seetest.groovy”
  • 57. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International step 6. build Web Service Test Scripts via SoapUI with the object oriented way (6 of 8) method “getNickname()” returns an auto-generated nickname based on pattern (4 letters + 4 numbers)
  • 58. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International in SoapUI Project update groovy Step “GenerateNickName” (for all test cases) to call method “getNickname()” from the External Groovy Script “seetest.groovy” step 6. build Web Service Test Scripts via SoapUI with the object oriented way (7 of 8) * above implementation is based on GroovyScriptEngine: http://docs.groovy-lang.org/latest/html/api/groovy/util/GroovyScriptEngine.html
  • 59. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International the implementation of method “getNickname()” is now out of SoapUI which means that any change about how the nickname should be, will affect only External Groovy Script “seetest.groovy”. step 6. build Web Service Test Scripts via SoapUI with the object oriented way (8 of 8) a full run proves that tests work properly.
  • 60. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International update Web Service Test Scripts based on Request for Change (RfC) step 7
  • 61. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International so, in a next release of the application, our customer decided to request a change regarding the nickname. the pattern must change from “4 letters and 4 numbers” to “4 letters and 6 numbers”. step 7. update Web Service Test Scripts based on Request for Change (RfC)(1 of 4)
  • 62. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International based on the 2 different implementation methodologies in SoapUI (step 5 & step 6), below is displayed a table of affections: step 7. update Web Service Test Scripts based on Request for Change (RfC)(2 of 4) Common Methodology Object Oriented Methodology Affected Test Steps in SoapUI 3 0 Affected External Groovy Scripts 0 1
  • 63. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International based on common methodology each “GenerateNickName” must be updated in SoapUI. step 7. update Web Service Test Scripts based on Request for Change (RfC)(3 of 4) in this demo project effort seems to be low, but when we are talking about hundreds of affected test cases and when the update is not such simple allowing us to make a simple Search-Replace in the SoapUI Project XML file, then maintenance is a real bottleneck.
  • 64. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International based on object oriented methodology nothing should be updated in SoapUI. Only method “getNickname()” of the external groovy script “seetest.groovy” must be updated properly. step 7. update Web Service Test Scripts based on Request for Change (RfC)(4 of 4) the fact that the effort relates to only one point outside SoapUI makes not only maintenance easier in terms of the needed actions but also in terms of guidelines. When we deliver a SoapUI project and something goes wrong it is easier to suggest workarounds by simply editing content of groovy files than giving workarounds with actions inside SoapUI steps.
  • 65. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International in conclusion (1 of 3) there is a minor disadvantage of using External Groovy Scripts:  when a part of external groovy method has failure, we must work with 2 different environments. Meaning that the script can be opened e.g. with Notepad++ (it cannot be opened via SoapUI directly to quickly edit the script and proceed. tip: we usually work with external groovy files via IntelliJ Community Edition having installed the Groovy SDK. http://groovy-lang.org/download.html there we can run and debug groovy scripts and find easier all the needed “imports”.
  • 66. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International in conclusion (2 of 3) the advantage of the easier maintenance and the external handling is such significant that makes the selection of this methodology a real need. and after this easier maintenance, we feel like… MVPs
  • 67. 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International in conclusion (3 of 3) of course, there are applications, where the number of test cases is not large, or the resources (test engineers) have not the necessary skills. there is no right or wrong based on the project’s needs… the decision is yours to make
  • 68. where to find the SoapUI Projects?  GitHub: https://github.com/vpetrou/srv-tests-soapui 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
  • 69. where to find me?  my GitHub: https://github.com/vpetrou  my LinkedIn Profile: https://www.linkedin.com/in/vasilis-petrou-09a785a3/  my Emails: vasilios.petrou@intrasoft-intl.com petrou82@gmail.com vasilis.petrou@outlook.com.gr 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International
  • 70. thank you questions? 15th Thessaloniki Software Testing and QA MeetupVasilis PETROU | Test Automation Lead | INTRASOFT International