ToolJet/server/test/modules
Shantanu Mane 89448cf492
Feature: Group Admin (#16210)
* fix: add FK constraints, unique constraint, and down() to group_admins migration

* fix: add explicit FK constraint names to group_admins migration

* feat: add GroupAdmin TypeORM entity

* fix: add Organization relation to GroupAdmin entity

* feat: add group-admin FEATURE_KEY entries and feature configs

* feat: add CE no-op stub for GroupAdminService

* feat: register GroupAdminService/Controller in module; add group-admin controller (CE stub + EE impl)

* feat: pass user to getAllGroup(); update interface and CE service signature

* test: add e2e tests for group-admin assign, revoke, scoped access, and auto-revocation

* fix: correct imports and tsconfig for group-admin e2e test

- fix entity imports: use @entities alias instead of src/entities
- fix module imports: use @modules alias instead of src/modules
- remove unused findEntityOrFail import from test-helper
- add jest to tsconfig types array for test type definitions
- add test-helper path mapping to tsconfig for proper resolution

* fix: register GroupAdmin entity in TypeOrmModule.forFeature for DI

* fix: grant workspace admins all group-admin feature keys in ability factory

* feat: add group-admin service methods

Add getGroupAdmins, getAddableAdmins, assignGroupAdmin, revokeGroupAdmin methods to groupPermissionV2Service following existing fetch pattern.

* feat: allow group-admin builders to access Groups link in workspace settings

Add is_group_admin and canManageGroups to conditionObj (both useState initializer
and subscribe handler). Change Groups link condition from ['admin'] to
['canManageGroups'] to allow admin OR group-admin builders.

* feat: add Group Admins tab to group permission resources

* fix: handle missing default groups for group-admin builders; hide admin-only controls

* feat: make permissions and granular access tabs read-only for group-admin builders; hide role-change in users tab

* feat: implement GroupAdminOrAdminRoute for session validation; enhance group admin management features

* feat: add GET_USER_ADMIN_GROUPS feature and update related permissions; enhance user group management

* feat: enhance group admin functionality; add builder role and improve admin assignment tests

* Fix: Add compiler options to tsconfig.build.json

* refactor: revert configs for test suite

* feat: enhance group admin functionality with feature access checks and user removal permissions

* feat: add option to duplicate group admins in duplicate group

* feat: enhance group permissions management

- Updated FeatureAbilityFactory to include additional checks for builder permissions and group-specific access.
- Modified GroupPermissionsController to apply FeatureAbilityGuard for various endpoints, ensuring proper permission checks.
- Enhanced GranularPermissionsController with appropriate guards for better access control.
- Refactored GroupExistenceGuard to improve group validation logic and error handling.
- Updated GroupPermissionsModule to streamline service and utility registrations.
- Added unit tests for FeatureAbilityFactory and GroupExistenceGuard to ensure robust permission handling.

* feat: implement afterUpdateUserRole method in RolesService

* feat: refactor GroupPermissionsUtilService usage in GroupPermissionsModule

* feat: enhance group permissions copyright and icons, minor bug fixes:

* Bug fixes

Co-authored-by: Copilot <copilot@github.com>

* bugz

Co-authored-by: Copilot <copilot@github.com>

---------

Co-authored-by: Rudhra Deep Biswas <rudra21ultra@gmail.com>
Co-authored-by: Copilot <copilot@github.com>
2026-04-30 19:29:03 +05:30
..
__fixtures__/tooljetdb-data-operations.spec/ToolJet-DB-data-operations-EE-enterprise_1253369290 Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
app/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
apps/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
audit-logs/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
auth/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
data-queries Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
data-sources/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
encryption/unit Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
files/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
folder-apps/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
folders/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
group-permissions Feature: Group Admin (#16210) 2026-04-30 19:29:03 +05:30
import-export-resources/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
instance-settings/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
library-apps/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
licensing refactor: improve license test setup for better readability 2026-04-15 11:17:18 +05:30
onboarding/e2e Fix: Preserve Auth Invite Token (#15887) 2026-04-13 10:49:18 +05:30
org-constants/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
organization-users/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
organizations/e2e Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
session Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
tooljet-db Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
users Chore: Rehabilitate backend test suite (#15740) 2026-04-08 13:09:49 +05:30
workflows Fix: Allow Workflow Access Across All Environments (#15981) 2026-04-21 14:41:22 +05:30