@@ -56,3 +56,58 @@ describe.skip('modifier-text-allowed-chars minus sign', () => {
56
56
} ) ;
57
57
58
58
} ) ;
59
+
60
+ describe . skip ( 'modifier-text-allowed-chars special chars' , ( ) => {
61
+
62
+ const speech = new SpeechMarkdown ( ) ;
63
+
64
+ const markdown = dedent `
65
+ This is text with (parens) but this and other special characters: []()*~@#\\_!+- are ignored
66
+ ` ;
67
+
68
+ test ( 'converts to SSML - Amazon Alexa' , ( ) => {
69
+
70
+ const options = {
71
+ platform : 'amazon-alexa'
72
+ } ;
73
+ const ssml = speech . toSSML ( markdown , options ) ;
74
+
75
+ const expected = dedent `
76
+ <speak>
77
+ This is text with (parens) but this and other special characters: []()*~@#\\_!+- are ignored
78
+ </speak>
79
+ ` ;
80
+
81
+ expect ( ssml ) . toBe ( expected ) ;
82
+ } ) ;
83
+
84
+ test ( 'converts to SSML - Google Assistant' , ( ) => {
85
+
86
+ const options = {
87
+ platform : 'google-assistant'
88
+ } ;
89
+ const ssml = speech . toSSML ( markdown , options ) ;
90
+
91
+ const expected = dedent `
92
+ <speak>
93
+ This is text with (parens) but this and other special characters: []()*~@#\\_!+- are ignored
94
+ </speak>
95
+ ` ;
96
+
97
+ expect ( ssml ) . toBe ( expected ) ;
98
+ } ) ;
99
+
100
+ test ( 'converts to Plain Text' , ( ) => {
101
+
102
+ const options = {
103
+ } ;
104
+ const text = speech . toText ( markdown , options ) ;
105
+
106
+ const expected = dedent `
107
+ This is text with (parens) but this and other special characters: []()*~@#\\_!+- are ignored
108
+ ` ;
109
+
110
+ expect ( text ) . toBe ( expected ) ;
111
+ } ) ;
112
+
113
+ } ) ;
0 commit comments