Spring: Test-Driven Development with JUnit

Spring: Test-Driven Development with JUnit

1h 13mIntermediate2017-09-14

Authors

Shonna Smith

Shonna Smith

Entrepreneur, Agile Coach, Enterprise Software Developer

Course details

Practicing test-driven development in the Spring framework—or any framework, for that matter—can help you speed up your software release cycles, and ensure that you end up with a high-quality product. Learn the tricks for using Spring and JUnit— an open-source testing tool—together, and how to use this power combo across your entire backend stack to achieve optimal test coverage. In this course, discover how (and why) to use Spring and JUnit for test-driven development. Instructor Shonna Smith also shows how to lay the groundwork for testing some typical components in your backend application: @Service, @Controller, and @Repository components. Throughout the course, Shonna provides hands-on examples of how to apply these concepts in a real-world application.

Learning objectives
Why test-driven development matters
Test planning for @Service, @Controller, and @Repository components
Writing integration tests for @Service, @Controller, and @Repository components
Writing unit tests for @Service, @Controller, and @Repository components
Creating integration test datasets
Making a feature test suite
Making a continuous integration test suite

Skills covered

JUnitSpring FrameworkSpring BootSpringSoftware TestingDevOps FoundationsDevOpsSoftware Development ToolsOpen SourceSoftware Development

Concepts

Introduction

  • Welcome
  • What you need to know
  • Using the exercise files

Review of TDD and Application

  • Why TDD matters
  • Introducing the sample application

Testing Spring Service Components

  • Test planning for @Service components
  • Write integration tests for @Service
  • Write unit tests for @Service

Testing Spring Controllers

  • Test planning for @Controller components
  • Write integration tests for @Controller
  • Write unit tests for @Controller

Testing Spring Data Access Components

  • Test planning for @Repository components
  • Write integration tests for @Repository
  • Create integration test datasets

Creating Test Suites - Putting It All Together

  • Make a feature test suite
  • Make a continuous integration test suite

Conclusion

  • Next steps
40,000 Toman