[AZ-189] [AZ-190] [AZ-191] [AZ-192] [AZ-193] [AZ-194] [AZ-195] Add e2e blackbox test suite

Made-with: Cursor
This commit is contained in:
Oleksandr Bezdieniezhnykh
2026-04-16 06:25:36 +03:00
parent 1b38e888e1
commit d320d6dd59
98 changed files with 6883 additions and 1 deletions
@@ -0,0 +1,37 @@
# Module: Azaion.Common.Extensions.EnumExtensions
## Purpose
Static utility class for extracting `DescriptionAttribute` values from enum members and retrieving default enum values.
## Public Interface
| Method | Signature | Description |
|--------|-----------|-------------|
| `GetDescriptions<T>` | `static Dictionary<T, string> GetDescriptions<T>() where T : Enum` | Returns all enum values mapped to their `[Description]` text |
| `GetDescription` | `static string GetDescription(this Enum enumValue)` | Extension: gets the `[Description]` of a single enum value |
| `GetDefaultValue<TEnum>` | `static TEnum GetDefaultValue<TEnum>() where TEnum : struct` | Returns the `[DefaultValue]` attribute's value for an enum type |
## Internal Logic
- `GetDescriptions<T>` iterates all enum values via `Enum.GetValues`, using a private helper `GetEnumAttrib` to extract the `DescriptionAttribute` via reflection. Falls back to `.ToString()` when no attribute exists.
- `GetEnumAttrib<T, TAttrib>` fetches a custom attribute from an enum member's `FieldInfo`.
## Dependencies
- `System.ComponentModel.DescriptionAttribute`, `System.Reflection` (BCL only)
## Consumers
- `BusinessException` (static constructor calls `GetDescriptions<ExceptionEnum>()`)
## Data Models
None.
## Configuration
None.
## External Integrations
None.
## Security
None.
## Tests
None.