Skip to content

Commit 9098d9b

Browse files
committed
Additional tests
1 parent fcf0375 commit 9098d9b

File tree

1 file changed

+22
-2
lines changed

1 file changed

+22
-2
lines changed

tests/Slugify.Core.Tests/SlugHelperTests.cs

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -705,10 +705,9 @@ public void TestHandlingOfUnicodeCharacters(ISlugHelper helper)
705705

706706

707707
[Fact]
708-
public void TurkishEncodingOfI()
708+
public void TurkishEncodingOfI_NonAscii()
709709
{
710710
var defaultCulture = CultureInfo.CurrentCulture;
711-
712711
try
713712
{
714713
//Set culture to Turkish
@@ -725,7 +724,28 @@ public void TurkishEncodingOfI()
725724
//Reset culture
726725
CultureInfo.CurrentCulture = defaultCulture;
727726
}
727+
}
728+
729+
[Fact]
730+
public void TurkishEncodingOfI()
731+
{
732+
var defaultCulture = CultureInfo.CurrentCulture;
733+
try
734+
{
735+
//Set culture to Turkish
736+
CultureInfo.CurrentCulture = new CultureInfo("tr-TR");
737+
const string original = "FIFA 18";
738+
const string expected = "fifa-18";
728739

740+
var helper = Create();
741+
742+
Assert.Equal(expected, helper.GenerateSlug(original));
743+
}
744+
finally
745+
{
746+
//Reset culture
747+
CultureInfo.CurrentCulture = defaultCulture;
748+
}
729749
}
730750

731751
[Fact]

0 commit comments

Comments
 (0)