public async Task InitMyCustomerPaginationTestAsync() { var mock = new Mock <IPaginationService>(); mock.Setup(a => a.InitMyCustomerPaginationAsync(1, "petya")).Returns(Task.FromResult(new IndexOutput())); var component = new PaginationService(PostgreContext, UserService); var result = await component.InitMyCustomerPaginationAsync(3, "petya"); Assert.IsNotNull(result); }