RulesEngine/test/RulesEngine.UnitTest/CustomTypeProviderTests.cs

45 lines
1.0 KiB
C#
Raw Permalink Normal View History

2019-08-13 06:06:57 -04:00
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
using Moq;
using System;
using System.Diagnostics.CodeAnalysis;
using Xunit;
2019-08-13 06:06:57 -04:00
namespace RulesEngine.UnitTest
{
[Trait("Category", "Unit")]
[ExcludeFromCodeCoverage]
2019-08-13 06:06:57 -04:00
public class CustomTypeProviderTests : IDisposable
{
private readonly MockRepository _mockRepository;
2019-08-13 06:06:57 -04:00
public CustomTypeProviderTests()
{
_mockRepository = new MockRepository(MockBehavior.Strict);
2019-08-13 06:06:57 -04:00
}
public void Dispose()
{
_mockRepository.VerifyAll();
2019-08-13 06:06:57 -04:00
}
private CustomTypeProvider CreateProvider()
{
return new CustomTypeProvider(null);
}
[Fact]
public void GetCustomTypes_StateUnderTest_ExpectedBehavior()
{
// Arrange
var unitUnderTest = CreateProvider();
2019-08-13 06:06:57 -04:00
// Act
var result = unitUnderTest.GetCustomTypes();
// Assert
Assert.NotEmpty(result);
}
}
}