Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eliasnogueira/448cef30d377d8855e6abca2eb833235 to your computer and use it in GitHub Desktop.
Save eliasnogueira/448cef30d377d8855e6abca2eb833235 to your computer and use it in GitHub Desktop.
How to create modularity microservice test projects

Title

How to create modular microservice test projects

Description

The world is now full of distributed micro-services, generating different types of applications: the ones you are using to browse your social networks, to help professionals spend less time on repetitive tasks, and even to save lives.

We learned that testing the API layer with different approaches brings several benefits but also a complexity that can be measured in code duplication, high maintenance costs, and error-prone tests.

To solve this problem, in terms of how to test it, we can apply the same logic applied in microservices development: isolating them.

By creating a client and test projects for each microservice we can provide methods that other test projects can consume, easily enabling e2e tests creation.

During this presentation, I will show to you how we can create it from scratch or decompose an existing test project and a real success case of a company that delivers hundreds of microservices to its customers.

Elevator Pitch

Testing microservices is a day-by-day activity for any team member and highly required to deliver bug-free services. Most software engineers create tests that can be seen only inside de microservice project, where others cannot be beneficial. Apply the approach proposed by this presentation will enable any team to use the test clients, speed up the testing process, and enable e2e tests.

Technologies in use

The knowledge acquired after this presentation can be applied with any programming language, however I will use the following technologies, in which I feel most comfortable: Java as the programming language with JUnit 5 to support the test creation supported by Maven. RestAssured as the library to test and validating REST services.

Targeting audience

Software Engineers at any seniority level that wants to improve theirs distributes microservices test projects.

Takeaways

After this presentation the audience will be able to:

  • Create test projects that are modular and reusable
  • Create functional test for microservices
  • Develop e2e microservices tests focusing on the business needs
  • Implement a practical microservice test approach in your projects
@yugoccp
Copy link

yugoccp commented Sep 5, 2020

Hi @eliasnogueira!

Looking forward at this presentation :)! My English is not the best, but here are my small suggestions:

Description

- code duplication, high maintenance, and error-prone tests.
+ code duplication, high maintenance cost, and error-prone tests.

- I will show how we can create this approach or decompose an existing test project through live coding and a real case of how this approach benefits a company that delivers hundreds of microservices to its customers.
+ I will show you how we can apply those techniques to decompose an existing test project and a real success case of a company that delivers hundreds of microservices to its customers.

Takeaways

- How to functional test microservices
+ How to create functional test microservices

@eliasnogueira
Copy link
Author

Thank you so much @yugoccp!
I've changed the second description suggestion replacing by another sentence: I will show to you how we can create it from scratch or decompose an existing test project and a real success case of a company that delivers hundreds of microservices to its customers.

I did this because I'll show how to create by scratch or change an existing project to decompose it.
What do you think?

@yugoccp
Copy link

yugoccp commented Sep 6, 2020

Thank you so much @yugoccp!
I've changed the second description suggestion replacing by another sentence: I will show to you how we can create it from scratch or decompose an existing test project and a real success case of a company that delivers hundreds of microservices to its customers.

I did this because I'll show how to create by scratch or change an existing project to decompose it.
What do you think?

Sounds great @eliasnogueira !

@brjavaman
Copy link

Suggestion for the takeaways:

After this presentation you will:

  • Create test projects that are modular and reusable
  • Create functional test for microservices
  • Develop e2e microservices tests focusing on the business needs
  • Implement a practical microservice test approach in your projects

(use actionable things)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment