SlideShare a Scribd company logo
1 of 38
THE ESSENTIAL TOOLS FOR TEST
CODE QUALITY IMPROVEMENT
QAA Geek and Java fan.
Consultant, speaker and
open-source contributor.
• Lead QAA Engineer
• Consultant: http://sdclabs.com
• GitHub contributor: sskorol
Speaker’s info
• Email: serhii.s.korol@gmail.com
• Twitter: @ss_korol
Contacts
Sergey Korol
Waverley Software
‘‘
2
WHO AM I?
WHAT IS CODE QUALITY?
● Easy to understand
● Easy to maintain
● Easy to use
● Works correctly
Some say:
● High quality == meets
requirements
Some say:
● Reliability
● Maintainability
● Efficiency
● Security
● Size
Some (CISQ) say:
3
4
4
BUT IT’S NOT ABOUT MODERN
TEST AUTOMATION
5
5
...and I should
care, why?
IMPROVEMENT STEPS
• Checkstyle, PMD, FindBugs usage
• IDE integration
• Pre-commit Git hook setup
Quality tools integration
Continuous integration
• Integrate Sonar into CI flow
• Quality metrics analysis
Sonar integration
6
• Jenkins pipeline and quality reports
• Tests execution in Docker
8
7
GRADLE QUALITY PLUGIN
9
8
QUALITY RULES INTEGRATION INTO IDE
10
9
PRE-COMMIT GIT HOOK
QUALITY TOOLS INTEGRATION
10
12
11
Predictability of
design
Industry
standards
Learn from
mistakes
Rules are not
set in stone
13
12
Selenoid Allure
CONTUNUOUS INTEGRATION
14
13
M: ui-testswebhooks
Create PR job
PR
Checkout
Parse Jenkinsfile
Start services
Run quality checks / tests
Publish results
F: ui-tests
15
14
webhooks
Create PR job
PR
Checkout
Parse Jenkinsfile
Start services
Run quality checks / tests
Publish results
M: ui-tests
F: ui-tests
16
15
webhooks
Create PR job
PR
Checkout
Parse Jenkinsfile
Start services
Run quality checks / tests
Publish results
M: ui-tests
F: ui-tests
17
16
webhooks
Create PR job
PR
Checkout
Parse Jenkinsfile
Start services
Run quality checks / tests
Publish results
M: ui-tests
F: ui-tests
18
17
webhooks
Create PR job
PR
Checkout
Start services
Run quality checks / tests
Publish results
Parse Jenkinsfile
M: ui-tests
F: ui-tests
19
18
webhooks
Create PR job
PR
Checkout
Start services
Run quality checks / tests
Publish results
Parse Jenkinsfile
M: ui-tests
F: ui-tests
20
19
webhooks
Create PR job
PR
Checkout
Start services
Run quality checks / tests
Publish results
Parse Jenkinsfile
M: ui-tests
F: ui-tests
21
20
webhooks
Create PR job
PR
Checkout
Stop services
Run quality checks / tests
Publish results
Parse Jenkinsfile
M: ui-tests
F: ui-tests
22
21
webhooks
Create PR job
PR
Checkout
Stop services
Run quality checks / tests
Publish results
Parse Jenkinsfile
M: ui-tests
F: ui-tests
23
22
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
24
23
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
25
24
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
26
25
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
27
26
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
28
27
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
29
28
CONTINUOUS INTEGRATION
stage(‘Checkout’) {
checkout scm
}
stage(‘Start services’) {
sh “docker-compose up –d”
}
stage(‘Quality checks / tests’) {
sh ”./gradlew clean check”
}
stage(‘Stop services’) {
sh “docker-compose down”
}
stage(‘Publish Allure report’) {
publish.allureReport()
}
stage(‘Publish quality report’) {
publish.checkstyleReport()
publish.pmdReport()
publish.findbugsReport()
}
30
29
CONTINUOUS INTEGRATION
react-app:
image: “sskorol/app:${TAG}”
network_mode: bridge
expose:
- “3000”
selenoid:
image: “aerokube/selenoid”
network_mode: bridge
ports:
- “4444:4444”
links:
- react-app
environment:
- DOCKER_API_VERSION=1.35
volumes:
- “${WORK_DIR}:/etc/selenoid”
- “//var/run/docker.sock:/var/run/docker.sock”
31
30
CONTINUOUS INTEGRATION
react-app:
image: “sskorol/app:${TAG}”
network_mode: bridge
expose:
- “3000”
selenoid:
image: “aerokube/selenoid”
network_mode: bridge
ports:
- “4444:4444”
links:
- react-app
environment:
- DOCKER_API_VERSION=1.35
volumes:
- “${WORK_DIR}:/etc/selenoid”
- “//var/run/docker.sock:/var/run/docker.sock”
32
31
CONTINUOUS INTEGRATION
react-app:
image: “sskorol/app:${TAG}”
network_mode: bridge
expose:
- “3000”
selenoid:
image: “aerokube/selenoid”
network_mode: bridge
ports:
- “4444:4444”
links:
- react-app
environment:
- DOCKER_API_VERSION=1.35
volumes:
- “${WORK_DIR}:/etc/selenoid”
- “//var/run/docker.sock:/var/run/docker.sock”
33
32
Fail fast,
fail often
Better visibility and
responsibility
Quality checks
as a part of CI
Easier code
review
34
33
SONAR INTEGRATION
35
M: ui-tests
PR
webhooks
34
SONAR INTEGRATION
F: ui-tests
36
36
Continuous
Inspection
DevOps
Integration
Centralized
Quality
Community or
Enterprise?
37
37
It’s not enough to
write the code well…
Try to make it a
little better than
you found it.
FIND OUT MORE
LinksAuthor
38

More Related Content

Similar to The essential tools for test code quality improvement latest

Modern SDLC and QA.pptx
Modern SDLC and QA.pptxModern SDLC and QA.pptx
Modern SDLC and QA.pptx
Zaid Shabbir
 
Session 3 - CloudStack Test Automation and CI
Session 3 - CloudStack Test Automation and CISession 3 - CloudStack Test Automation and CI
Session 3 - CloudStack Test Automation and CI
tcloudcomputing-tw
 

Similar to The essential tools for test code quality improvement latest (20)

Building Autonomous Operations for Kubernetes with keptn
Building Autonomous Operations for Kubernetes with keptnBuilding Autonomous Operations for Kubernetes with keptn
Building Autonomous Operations for Kubernetes with keptn
 
A Guide to Event-Driven SRE-inspired DevOps
A Guide to Event-Driven SRE-inspired DevOpsA Guide to Event-Driven SRE-inspired DevOps
A Guide to Event-Driven SRE-inspired DevOps
 
How I Pass Qlik Sense System Administrator (QSSA2022) Exam?
How I Pass Qlik Sense System Administrator (QSSA2022) Exam?How I Pass Qlik Sense System Administrator (QSSA2022) Exam?
How I Pass Qlik Sense System Administrator (QSSA2022) Exam?
 
Continuous Delivery: How RightScale Releases Weekly
Continuous Delivery: How RightScale Releases WeeklyContinuous Delivery: How RightScale Releases Weekly
Continuous Delivery: How RightScale Releases Weekly
 
Model-based Testing: Taking BDD/ATDD to the Next Level
Model-based Testing: Taking BDD/ATDD to the Next LevelModel-based Testing: Taking BDD/ATDD to the Next Level
Model-based Testing: Taking BDD/ATDD to the Next Level
 
PuppetConf 2017: Test First Approach for Puppet on Windows- Miro Sommer, Hiscox
PuppetConf 2017: Test First Approach for Puppet on Windows- Miro Sommer, HiscoxPuppetConf 2017: Test First Approach for Puppet on Windows- Miro Sommer, Hiscox
PuppetConf 2017: Test First Approach for Puppet on Windows- Miro Sommer, Hiscox
 
QA Fest 2017. Владимир Примаков. QA метрики. Взгляд на качество с разных стор...
QA Fest 2017. Владимир Примаков. QA метрики. Взгляд на качество с разных стор...QA Fest 2017. Владимир Примаков. QA метрики. Взгляд на качество с разных стор...
QA Fest 2017. Владимир Примаков. QA метрики. Взгляд на качество с разных стор...
 
Project P Open Workshop
Project P Open WorkshopProject P Open Workshop
Project P Open Workshop
 
Modern SDLC and QA.pptx
Modern SDLC and QA.pptxModern SDLC and QA.pptx
Modern SDLC and QA.pptx
 
CI CD OPS WHATHAVEYOU
CI CD OPS WHATHAVEYOUCI CD OPS WHATHAVEYOU
CI CD OPS WHATHAVEYOU
 
Quality in a Square. K8s-native Quality Assurance of Microservices with Testkube
Quality in a Square. K8s-native Quality Assurance of Microservices with TestkubeQuality in a Square. K8s-native Quality Assurance of Microservices with Testkube
Quality in a Square. K8s-native Quality Assurance of Microservices with Testkube
 
AQA_You are_Soaking_In_It_DevNexus2020
AQA_You are_Soaking_In_It_DevNexus2020AQA_You are_Soaking_In_It_DevNexus2020
AQA_You are_Soaking_In_It_DevNexus2020
 
QA Fest 2015. Владимир Примаков. Процесс нагрузочного тестирования и его план...
QA Fest 2015. Владимир Примаков. Процесс нагрузочного тестирования и его план...QA Fest 2015. Владимир Примаков. Процесс нагрузочного тестирования и его план...
QA Fest 2015. Владимир Примаков. Процесс нагрузочного тестирования и его план...
 
Reliability Pipelines With Keptn Quality Gates
Reliability Pipelines With Keptn Quality GatesReliability Pipelines With Keptn Quality Gates
Reliability Pipelines With Keptn Quality Gates
 
How Vanguard Got to a CD-CD World by Craig Schwarzwald
How Vanguard Got to a CD-CD World by Craig SchwarzwaldHow Vanguard Got to a CD-CD World by Craig Schwarzwald
How Vanguard Got to a CD-CD World by Craig Schwarzwald
 
Quadratisch. Praktisch. Gut. K8s-native Quality Assurance mit Testkube @ Java...
Quadratisch. Praktisch. Gut. K8s-native Quality Assurance mit Testkube @ Java...Quadratisch. Praktisch. Gut. K8s-native Quality Assurance mit Testkube @ Java...
Quadratisch. Praktisch. Gut. K8s-native Quality Assurance mit Testkube @ Java...
 
Jenkins Declarative Pipelines 101
Jenkins Declarative Pipelines 101Jenkins Declarative Pipelines 101
Jenkins Declarative Pipelines 101
 
QSDA2022: Qlik Sense Data Architect | Q & A
QSDA2022: Qlik Sense Data Architect | Q & AQSDA2022: Qlik Sense Data Architect | Q & A
QSDA2022: Qlik Sense Data Architect | Q & A
 
Software testing course - Manual
Software testing course - ManualSoftware testing course - Manual
Software testing course - Manual
 
Session 3 - CloudStack Test Automation and CI
Session 3 - CloudStack Test Automation and CISession 3 - CloudStack Test Automation and CI
Session 3 - CloudStack Test Automation and CI
 

Recently uploaded

The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
heathfieldcps1
 

Recently uploaded (20)

Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptxExploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
 
Wellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptxWellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptx
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptx
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptxOn_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptx
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
 

The essential tools for test code quality improvement latest