Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
course-material
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IT1901
course-material
Commits
9b0acf55
Commit
9b0acf55
authored
3 years ago
by
George Adrian Stoica
Browse files
Options
Downloads
Patches
Plain Diff
docs: add slides for lecture 18
parent
3b8395bb
No related branches found
No related tags found
No related merge requests found
Pipeline
#145383
passed
3 years ago
Stage: build
Stage: test
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lectures/revealjs/18-lecture-integration-testing.adoc
+106
-0
106 additions, 0 deletions
lectures/revealjs/18-lecture-integration-testing.adoc
with
106 additions
and
0 deletions
lectures/revealjs/18-lecture-integration-testing.adoc
0 → 100644
+
106
−
0
View file @
9b0acf55
= Integration testing
:customcss: slides.css
:icons: font
:includedir: includes/
:LECTURE_TOPIC: Integration testing
:LECTURE_NO: 18th Lecture
include::{includedir}header.adoc[]
[.smaller-80][.center-paragraph]
IT1901 Fall 2021 - {LECTURE_NO}
[background-color = "#124990"]
[color = "#fff6d5"]
== Testing
- is an important part of software development
- a way to ensure software quality
- automated testing allows to develop new features with a minimal effort to check if the software still works as expected
- testing frameworks
== Testing principles
- testing shows presence of defects (not their absence)
- testing all possibilities is not feasible
- testing should be started as early as possible
- testing depends on the context
== Levels of testing
- Unit testing
- *Integration testing*
- System testing
- Deployment testing
== Unit testing
- units are the smallest testable parts of our system (methods, classes)
- unit tests are concerned with testing the unit in isolation
== Integration testing
- integration testing aims at testing several units / components
- the size and complexity of such a test is on a spectrum and can be from just integrating 2 units to integrating nearly all components in the system
== System testing
- testing the complete system as whole
- it can be considered a fully integrated test as it integrates all the components within the said system
- checks if the system is compliant with the specified requirements
== Deployment testing
- tests the complete system as it would be for actual use
- complete system should comply with the requirements in the clients' environment
== Testing pyramid
image::../images/lecture18/test-pyramid.png[canvas, size=contain]
== Testing pyramid (2)
- as we go from the bottom towards the top the tests get more complex and resource intensive
- the pyramid is a useful reminder that we should have many unit tests, several integration tests and very few system and deployment tests
== System-Tiers-Layers-Modules-Components-Units
image::../images/lecture18/system-units.png[canvas, size=contain]
== Unit tests
image::../images/lecture18/system-units.png[canvas, size=contain]
== Integration tests
image::../images/lecture18/integration-tests.png[canvas, size=contain]
== Types of integration testing
- "Big Bang" - all of units available are combined together and tested if they work together as intended
- "Top-Down" - top-down integration allows the team to test the top level units first (stubs)
- "Bottom-Up" - test the bottom level units first (drivers)
- "Hybrid" - a combination of both top-down and bottom-up integration testing
== Isolating parts of the system
- to be able to reliably and automatically test parts of the system we need to isolate them
- the parts need to have a clear contract (the interface used to interact and communicate)
- when parts of the system that the unit / component we want to test depends upon are not implemented these need to be simulated
- a simulated component is usually referred to as a mock, stub or fake
- when the simulated component is using / calling the tested component it is called a driver
== Simulating parts
image::../images/lecture18/mocked-server.png[canvas, size=contain]
== Simulating parts (2)
image::../images/lecture18/mocked-client.png[canvas, size=contain]
include::{includedir}footer.adoc[]
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment