@@ -681,3 +681,33 @@ describe("#normalizeCustomHandlerPattern", () => {
681681 } ) ;
682682 } ) ;
683683} ) ;
684+
685+ describe ( "#slugify" , ( ) => {
686+ it ( "should return a slugified string" , ( ) => {
687+ const testString = "This is a Test String! With unicode & Special #Chars." ;
688+ const expectedSlug = "this-is-a-test-string-with-unicode-special-chars" ;
689+ const result = utils . slugify ( testString ) ;
690+ expect ( result ) . toBe ( expectedSlug ) ;
691+ } ) ;
692+
693+ it ( "supports CJK characters without alteration" , ( ) => {
694+ const testString = "测试中文字符" ;
695+ const expectedSlug = "测试中文字符" ;
696+ const result = utils . slugify ( testString ) ;
697+ expect ( result ) . toBe ( expectedSlug ) ;
698+ } ) ;
699+
700+ it ( "supports Cyrillic characters without alteration" , ( ) => {
701+ const testString = "Тестирование кириллических символов" ;
702+ const expectedSlug = "тестирование-кириллических-символов" ;
703+ const result = utils . slugify ( testString ) ;
704+ expect ( result ) . toBe ( expectedSlug ) ;
705+ } ) ;
706+
707+ it ( "removes diacritic marks from characters" , ( ) => {
708+ const testString = "Café naïve façade jalapeño" ;
709+ const expectedSlug = "cafe-naive-facade-jalapeno" ;
710+ const result = utils . slugify ( testString ) ;
711+ expect ( result ) . toBe ( expectedSlug ) ;
712+ } ) ;
713+ } ) ;
0 commit comments