Files
TeleWave/backend/tests/TeleWave.Application.Tests/Support/GroupServices.cs
T
Leonid Pershin 91af589547
ci / build-backend (push) Successful in 2m30s
ci / build-frontend (push) Successful in 43s
ci / tests (push) Successful in 2m36s
ci / sonar (push) Failing after 33s
Implement dynamic group management features with exclusions and mode handling
Enhanced the group management system by introducing dynamic group capabilities, allowing for the exclusion of elements from dynamic groups. Updated the Group and GroupItem models to support a new GroupMode, enabling the distinction between static and dynamic groups. Implemented API endpoints for excluding elements and updated related services to handle group composition based on the selected mode. Improved the frontend to accommodate these changes, including new API functions and UI components for managing exclusions and group modes, thereby enhancing the overall user experience in group management.
2026-07-27 05:03:09 +03:00

18 lines
768 B
C#

using TeleWave.Application.Common.Interfaces;
using TeleWave.Application.Programming.Groups;
namespace TeleWave.Application.Tests.Support;
/// <summary>
/// Сборка сервисов группы для тестов: их четыре и они цепляются друг за друга, а в тестах нужен
/// каждый раз один и тот же набор. В приложении это делает контейнер.
/// </summary>
internal static class GroupServices
{
public static DynamicGroupResolver Dynamic(IAppDbContext db) =>
new(new GroupFilterMatcher(db), new GroupElementResolver(db));
public static GroupStatsService Stats(IAppDbContext db) =>
new(db, new GroupElementResolver(db), Dynamic(db));
}