Skip to content

Commit cdbaea1

Browse files
committed
Add guidelines for updating test permissions in CONTRIBUTING.md
1 parent f840ba0 commit cdbaea1

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

CONTRIBUTING.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,12 @@ But now we are also ready to add new features.
7575
- Create a draft PR when starting work on bigger changes for discussion and assistance.
7676
- A **Task-board** and **Roadmap** are available for **contributors** to obtain additional information.
7777
78+
### Updating Test Permissions
79+
80+
When making changes that affect user permissions or app structures in the admin interface, update the expected data in `tests/main_menu_data.py` rather than modifying the test logic. This file contains `DATA` (for user roles) and `ADMIN_DATA` (for admin roles) dictionaries that define the expected app and model permissions for each role. Keeping this data centralized ensures tests remain maintainable and focused on validation.
81+
82+
For example, if a new permission is added or removed for a model, update the corresponding entries in these dictionaries to match the actual behavior.
83+
7884
> [!IMPORTANT]
7985
> 1. This repository follows the "[GitHub flow](https://docs.github.com/en/get-started/using-github/github-flow)" - anything in the main branch is deployable.
8086
> **Run tests before creating a Pull Request!**

0 commit comments

Comments
 (0)