DEV Community

Cover image for codecov.yml in Lobechat source code.
Ramu Narasinga
Ramu Narasinga

Posted on • Edited on

codecov.yml in Lobechat source code.

In this article, we analyze codecov.yml found in Lobechat repository I have seen codecov.yml in a lot of open source projects. So what is codecov.yml?

codecov.yml

Codecov by Sentry is the all-in-one code coverage and quality solution for any test suite — giving developers

actionable insights to deploy reliable code with confidence. Trusted by over 29,000 organizations.

Check out the codecov’s quick start guide.

codecov.yml in Lobechat

The below code snippet is picked from Lobechat.

coverage:
 status:
 project:
 default: off
 server:
 flags:
 - server
 app:
 flags:
 - app
 patch: off
Enter fullscreen mode Exit fullscreen mode

By default, Codecov will only show git diff coverage checks on a PR but it looks like Lobechat turned this off since the default is off. Check this guide, Set project coverage checks on a pull request, for more info.

For the server and the app, it has the flags, I found this documentation for flags on codecov.

You can group coverage reports based on type of tests or sub-projects/teams based on flags.

Flags allow you to isolate and categorize coverage reports for different tests and features in your project. This is particularly helpful if:

1. You have multiple types of tests (e.g., unit, integration, frontend, backend, etc) AND/OR

2. You’re employing a monorepo setup where you’d like to encapsulate each project’s test coverage independently.

This pull request has Codecov report. Here is an example of reports with flags.

About me:

Hey, my name is Ramu Narasinga. I study large open-source projects and create content about their codebase architecture and best practices, sharing it through articles, videos.

I am open to work on an interesting project. Send me an email at ramu.narasinga@gmail.com

My Github - https://github.com/ramu-narasinga
My website - https://ramunarasinga.com
My Youtube channel - https://www.youtube.com/@thinkthroo
Learning platform - https://thinkthroo.com
Codebase Architecture - https://app.thinkthroo.com/architecture
Best practices - https://app.thinkthroo.com/best-practices
Production-grade projects - https://app.thinkthroo.com/production-grade-projects

References:

1. https://about.codecov.io/

2. https://github.com/lobehub/lobe-chat/blob/main/codecov.yml

3. https://docs.codecov.com/docs/flags



Top comments (0)