Beispiel #1
0
            public void WhenIsSnakeCase_ThenReturnSameString()
            {
                var sut = "snake_case";

                var result = CaseConverter.ToSnakeCase(sut, CaseType.SnakeCase);

                Assert.That(result, Is.EqualTo(sut));
            }
Beispiel #2
0
 public void WhenIsNotCaseSpecified_ThenThrowException(string value)
 {
     Assert.Throws <ArgumentException>(() => CaseConverter.ToSnakeCase(value, CaseType.SnakeCase));
 }
Beispiel #3
0
            public void WhenIsSnakeUpperCase_ThenReturnString(string sut, string expected)
            {
                var result = CaseConverter.ToSnakeCase(sut, CaseType.SnakeUpperCase);

                Assert.That(result, Is.EqualTo(expected));
            }