add latest tests
This commit is contained in:
@@ -12,12 +12,10 @@ namespace ChatBot.Tests.Services;
|
||||
public class TelegramBotClientWrapperTests : UnitTestBase
|
||||
{
|
||||
private readonly Mock<ITelegramBotClient> _botClientMock;
|
||||
private readonly TelegramBotClientWrapper _wrapper;
|
||||
|
||||
public TelegramBotClientWrapperTests()
|
||||
{
|
||||
_botClientMock = TestDataBuilder.Mocks.CreateTelegramBotClient();
|
||||
_wrapper = new TelegramBotClientWrapper(_botClientMock.Object);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
@@ -60,9 +58,6 @@ public class TelegramBotClientWrapperTests : UnitTestBase
|
||||
[Fact]
|
||||
public void Wrapper_ShouldHaveGetMeAsyncMethod()
|
||||
{
|
||||
// Arrange
|
||||
var wrapper = new TelegramBotClientWrapper(_botClientMock.Object);
|
||||
|
||||
// Act & Assert
|
||||
var method = typeof(TelegramBotClientWrapper).GetMethod("GetMeAsync");
|
||||
method.Should().NotBeNull();
|
||||
@@ -176,16 +171,10 @@ public class TelegramBotClientWrapperTests : UnitTestBase
|
||||
public void Wrapper_ShouldHaveCorrectInterfaceMethods()
|
||||
{
|
||||
// Arrange
|
||||
var wrapper = new TelegramBotClientWrapper(_botClientMock.Object);
|
||||
var interfaceType = typeof(ITelegramBotClientWrapper);
|
||||
|
||||
// Act
|
||||
var interfaceMethods = interfaceType.GetMethods();
|
||||
var wrapperMethods = wrapper
|
||||
.GetType()
|
||||
.GetMethods()
|
||||
.Where(m => m.DeclaringType == wrapper.GetType())
|
||||
.ToArray();
|
||||
|
||||
// Assert
|
||||
interfaceMethods.Should().HaveCount(1);
|
||||
|
||||
Reference in New Issue
Block a user