Add channel system unit and integration tests

Comprehensive NUnit test suite covering ChannelManager, CliChannel,
TelegramChannel, DI registration, and integration scenarios. Uses
Moq for mocking with test stubs for isolated unit testing.
This commit is contained in:
2026-04-04 04:12:24 +02:00
parent 9a05bae4a9
commit f21d55d87d
12 changed files with 1300 additions and 0 deletions
@@ -0,0 +1,19 @@
using Luna.Channels.Abstractions;
using Luna.Shared;
namespace Luna.Channels.Tests.Stubs;
public class CliChannelStub : IChannel
{
public required string ChannelId { get; init; }
public string ChannelType => throw new NotImplementedException();
public string DisplayName => throw new NotImplementedException();
public bool IsConnected => throw new NotImplementedException();
public event ChannelMessageReceivedEventHandler? MessageReceived;
public event ChannelConnectionChangedEventHandler? ConnectionStateChanged;
public Task SendMessageAsync(ChannelMessage message, CancellationToken cancellationToken = default) => throw new NotImplementedException();
public Task SendStreamingMessageAsync(IAsyncEnumerable<ChatStreamUpdate> messageStream, CancellationToken cancellationToken = default) => throw new NotImplementedException();
public void RaiseMessageReceived(object? sender, ChannelMessage message) => throw new NotImplementedException();
public void Dispose() => throw new NotImplementedException();
}