add partial class test

This commit is contained in:
daver32
2022-07-26 20:22:27 +02:00
parent 611323840c
commit b51667e367
3 changed files with 31 additions and 0 deletions
@@ -0,0 +1,7 @@
namespace InterfaceGenerator.Tests.Partial;
[GenerateAutoInterface]
internal partial class PartialClass : IPartialClass
{
}
@@ -0,0 +1,8 @@
namespace InterfaceGenerator.Tests.Partial;
internal partial class PartialClass
{
public void SomeMethodThatShouldGenerate()
{
}
}
@@ -0,0 +1,16 @@
using System;
using FluentAssertions;
using InterfaceGenerator.Tests.Partial;
using Xunit;
namespace InterfaceGenerator.Tests;
public class PartialClassTests
{
[Fact]
public void GeneratesMethodFromOtherParts()
{
var tInterface = typeof(IPartialClass);
tInterface.GetMethods().Should().Contain(x => x.Name == nameof(PartialClass.SomeMethodThatShouldGenerate));
}
}