Skip to content

388 — should check when user have only project basic permission

Description

Verifies that an employee with only the "Projects basic" global user role can see every project's time budget (read-only on details, read-only in task modal) but the price budget remains hidden everywhere.

Preconditions

  • A signed-in owner who will create the role, plus an invited employee who will receive it.
  • Seed data: two projects (each with a workflow, a price budget of 200/100 and a task with budgets) plus one time record per project.

Steps

  1. As the owner, go to Roles → User roles, add a user role with the test title, toggle "Projects basic" on, then save. Expected: the new role exists.
  2. Assign the role to the invited employee via API and reset the session.
  3. Sign in as the employee and open the Projects list. Expected: both organization projects (2) are visible.
  4. Inspect the project list columns. Expected: the time budget column is visible with values matching the API response; the price budget column is hidden.
  5. Open the first project and switch to Project details. Expected: the time budget field is locked (read-only) and the price budget field is not rendered.
  6. Open the project's Tasks tab and use the column manager to enable "Time budget". Expected: the time budget column becomes visible with the seeded value; the price budget column stays hidden (its toggle is locked).
  7. Open the task row. Expected: in the task modal the time budget is locked and the price budget is not rendered.
  • Spec: playwright/tests/integration/permissions.spec.ts (line 853)