tests: begin the march to test coverage
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
namespace StevesBot.Worker.Tests.Unit;
|
||||
|
||||
public class DiscordCloseCodesTests
|
||||
{
|
||||
[Theory]
|
||||
[InlineData(4004, false)]
|
||||
[InlineData(4010, false)]
|
||||
[InlineData(4011, false)]
|
||||
[InlineData(4012, false)]
|
||||
[InlineData(4013, false)]
|
||||
[InlineData(4014, false)]
|
||||
[InlineData(null, true)]
|
||||
[InlineData(1000, true)]
|
||||
public void IsReconnectable_WhenCalledWithCloseCode_ItShouldReturnExpectedResult(int? closeCode, bool expected)
|
||||
{
|
||||
var result = DiscordCloseCodes.IsReconnectable(closeCode);
|
||||
|
||||
result.Should().Be(expected);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user