feat(application): CRUD handlers + validators + DI de ProductType (PRD-001)
Create/Update/Deactivate handlers con TransactionScope + audit; validators FluentValidation; DI wiring NullProductQueryRepository + 5 handlers; SqlTestFixture V017 + permiso count 25→26.
This commit is contained in:
@@ -73,7 +73,7 @@ public class PermisoRepositoryTests : IAsyncLifetime
|
||||
// ── ListAsync ────────────────────────────────────────────────────────────
|
||||
|
||||
[Fact]
|
||||
public async Task ListAsync_Returns25CanonicalSeeds()
|
||||
public async Task ListAsync_Returns26CanonicalSeeds()
|
||||
{
|
||||
var list = await _repository.ListAsync();
|
||||
|
||||
@@ -81,8 +81,9 @@ public class PermisoRepositoryTests : IAsyncLifetime
|
||||
// + V011 (ADM-001) adds 'administracion:secciones:gestionar'
|
||||
// + V013 (ADM-008) adds 'administracion:puntos_de_venta:gestionar'
|
||||
// + V014 (ADM-009) adds 'administracion:fiscal:gestionar'
|
||||
// + V016 (CAT-001) adds 'catalogo:rubros:gestionar' = 25 total
|
||||
Assert.Equal(25, list.Count);
|
||||
// + V016 (CAT-001) adds 'catalogo:rubros:gestionar'
|
||||
// + V017 (PRD-001) adds 'catalogo:tipos:gestionar' = 26 total
|
||||
Assert.Equal(26, list.Count);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
|
||||
@@ -173,16 +173,17 @@ public class RolPermisoRepositoryTests : IAsyncLifetime
|
||||
// ── GetByRolCodigoAsync ──────────────────────────────────────────────────
|
||||
|
||||
[Fact]
|
||||
public async Task GetByRolCodigoAsync_Admin_Returns25Permisos()
|
||||
public async Task GetByRolCodigoAsync_Admin_Returns26Permisos()
|
||||
{
|
||||
// admin has 18 permisos from V006 + 3 new admin permisos from V007 (UDT-006)
|
||||
// + 1 from V011 (ADM-001): 'administracion:secciones:gestionar'
|
||||
// + 1 from V013 (ADM-008): 'administracion:puntos_de_venta:gestionar'
|
||||
// + 1 from V014 (ADM-009): 'administracion:fiscal:gestionar'
|
||||
// + 1 from V016 (CAT-001): 'catalogo:rubros:gestionar' = 25 total
|
||||
// + 1 from V016 (CAT-001): 'catalogo:rubros:gestionar'
|
||||
// + 1 from V017 (PRD-001): 'catalogo:tipos:gestionar' = 26 total
|
||||
var permisos = await _repository.GetByRolCodigoAsync("admin");
|
||||
|
||||
Assert.Equal(25, permisos.Count);
|
||||
Assert.Equal(26, permisos.Count);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
|
||||
Reference in New Issue
Block a user