Перевести маркерные классы на маркерные интерфейсы

10 пустых классов-маркеров (модули, Contracts/Infrastructure/SharedKernel)
заменены интерфейсами IKanbanModule/ICardsModule/.../ISharedKernel по правилу
владельца: маркерные классы не используем. Файлы переименованы под имя типа,
тесты проверяют IsInterface + IsPublic.
This commit is contained in:
Rustam Khalimov
2026-09-11 20:18:17 +03:00
parent 206d61068a
commit 93e9100ae4
12 changed files with 19 additions and 19 deletions
@@ -3,6 +3,6 @@ namespace Deal.Contracts;
/// <summary>
/// Маркер слоя Contracts
/// </summary>
public sealed class ContractsMarker
public interface IContracts
{
}
@@ -3,6 +3,6 @@ namespace Deal.Infrastructure;
/// <summary>
/// Маркер слоя Infrastructure
/// </summary>
public sealed class InfrastructureMarker
public interface IInfrastructure
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Cards;
/// <summary>
/// Маркер модуля Cards
/// </summary>
public sealed class CardsModuleMarker
public interface ICardsModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Discovery;
/// <summary>
/// Маркер модуля Discovery
/// </summary>
public sealed class DiscoveryModuleMarker
public interface IDiscoveryModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Kanban;
/// <summary>
/// Маркер модуля Kanban
/// </summary>
public sealed class KanbanModuleMarker
public interface IKanbanModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Pipeline;
/// <summary>
/// Маркер модуля Pipeline
/// </summary>
public sealed class PipelineModuleMarker
public interface IPipelineModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Settings;
/// <summary>
/// Маркер модуля Settings
/// </summary>
public sealed class SettingsModuleMarker
public interface ISettingsModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Telegram;
/// <summary>
/// Маркер модуля Telegram
/// </summary>
public sealed class TelegramModuleMarker
public interface ITelegramModule
{
}
@@ -3,6 +3,6 @@ namespace Deal.Modules.Tenants;
/// <summary>
/// Маркер модуля Tenants
/// </summary>
public sealed class TenantsModuleMarker
public interface ITenantsModule
{
}
@@ -5,6 +5,6 @@ namespace Deal.SharedKernel;
/// <summary>
/// Маркер слоя SharedKernel
/// </summary>
public sealed class SharedKernelMarker
public interface ISharedKernel
{
}
@@ -11,10 +11,10 @@ namespace Deal.Tests.Unit.Modules.Cards;
public sealed class CardsDomainTests
{
[Fact]
public void CardsModuleMarker_IsPublicAndSealed()
public void ICardsModule_IsPublicInterface()
{
Assert.True(typeof(CardsModuleMarker).IsPublic);
Assert.True(typeof(CardsModuleMarker).IsSealed);
Assert.True(typeof(ICardsModule).IsPublic);
Assert.True(typeof(ICardsModule).IsInterface);
}
[Fact]
@@ -6,16 +6,16 @@ namespace Deal.Tests.Unit.Modules.Kanban;
public sealed class MarkerTests
{
[Fact]
public void PipelineModuleMarker_IsPublicAndSealed()
public void IPipelineModule_IsPublicInterface()
{
Assert.True(typeof(PipelineModuleMarker).IsPublic);
Assert.True(typeof(PipelineModuleMarker).IsSealed);
Assert.True(typeof(IPipelineModule).IsPublic);
Assert.True(typeof(IPipelineModule).IsInterface);
}
[Fact]
public void KanbanModuleMarker_IsPublicAndSealed()
public void IKanbanModule_IsPublicInterface()
{
Assert.True(typeof(KanbanModuleMarker).IsPublic);
Assert.True(typeof(KanbanModuleMarker).IsSealed);
Assert.True(typeof(IKanbanModule).IsPublic);
Assert.True(typeof(IKanbanModule).IsInterface);
}
}