DEV Community

Phuc Le
Phuc Le

Posted on

How unit tests help you onboard existing project

There Is always a time when you will join a project that was built a while ago, especially if you just join a new company or new organisation.

Besides documents, training ... I would suggest starting to write unit tests is one of my favourite approaches.

Benefits to write unit tests on existing source code:

  • Good understanding of the components is based on how the project is built which builds up your confidence.
  • Understand state management, data flow which you need to pass correctly by mocking the store when you do unit tests for pages, screens.
  • Understand and learn the coding style and from your team members
  • It might be one of your KPI for first month which it is good start to help improve code quantity

Especially writing unit tests when you join a big organisation with huge code on many layers, which nowadays design systems, composition components are becoming popular, you will realise that most of the time we are over-engineering and unnecessary layers.

Gook luck :)

Image of Wix Studio

2025: Your year to build apps that sell

Dive into hands-on resources and actionable strategies designed to help you build and sell apps on the Wix App Market.

Get started

Top comments (0)

πŸ‘‹ Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay