Skip to content

Commit

Permalink
doc: add TRG regarding application testing
Browse files Browse the repository at this point in the history
  • Loading branch information
ds-lcapellino committed Jan 3, 2025
1 parent 367e2e0 commit ae94df3
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/release/trg-10/_category_.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"label": "TRG 10 - Application Testing"
}
55 changes: 55 additions & 0 deletions docs/release/trg-10/trg-10-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
title: TRG 10.01 - Code Coverage
sidebar_position: 1
---

| Status | Created | Post-History |
|--------|-------------|---------------|
| Draft | 18-Dec-2024 | Create draft |

## Why

Ensure that all released software components meet sufficient test coverage to guarantee quality, stability, and reliability.
This guideline applies to all software components and projects that are part of the Tractus-X release process.
## Description

#### 1. Minimum Requirements

1.1. **Code Coverage Threshold**

- The minimum threshold for code coverage (line coverage) should be **80%**.
- This includes both unit tests and integration tests.

1.2. **Exceptions**

- Certain code sections may be excluded from coverage if they:
- Depend on hardware that cannot be simulated.
- Are experimental or prototypes.
- Are purely generated or boilerplate code or Entity classes.
- All exceptions should be documented and approved by the project leadership team.

#### 2. Analysis and Reporting

2.1. **Tools for Code Coverage Measurement**

- Recommended tools: [JaCoCo, SonarCloud]
- The tool used should be specified and documented within the project.

2.2. **Regular Review**

- Code coverage should be measured at least once before each release.
- Coverage measurement results should be integrated into CI/CD pipelines and automated as part of the release process.

#### 3. Quality Assurance

3.1. **Code Review Requirements**

- Reviewers should ensure that new or modified code sections are sufficiently tested.
- Code changes that lower the overall coverage below the threshold may only be accepted in exceptional cases.

3.2. **Risk Analysis**

- If the coverage value falls below 80%, the potential risks should be documented and approved by the release management team.



0 comments on commit ae94df3

Please sign in to comment.