exercism/csharp/sum-of-multiples/SumOfMultiplesTest.cs

47 lines
1.0 KiB
C#
Raw Normal View History

2017-08-12 14:01:07 +00:00
using Xunit;
public class SumOfMultiplesTest
{
[Fact]
public void Sum_to_1()
{
Assert.Equal(0, SumOfMultiples.To(new[] { 3, 5 }, 1));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_3()
{
Assert.Equal(3, SumOfMultiples.To(new[] { 3, 5 }, 4));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_10()
{
Assert.Equal(23, SumOfMultiples.To(new[] { 3, 5 }, 10));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_100()
{
Assert.Equal(2318, SumOfMultiples.To(new[] { 3, 5 }, 100));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_1000()
{
Assert.Equal(233168, SumOfMultiples.To(new[] { 3, 5 }, 1000));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_20()
{
Assert.Equal(51, SumOfMultiples.To(new [] { 7, 13, 17 }, 20));
}
[Fact(Skip = "Remove to run test")]
public void Sum_to_10000()
{
Assert.Equal(2203160, SumOfMultiples.To(new [] { 43, 47 }, 10000));
}
}