| 1167 | class TestRemoveAccents extends WPTestCase { |
| 1168 | // #17738 |
| 1169 | public function test_replaces_vowels_diacritic() { |
| 1170 | $this->assertEquals( 'OoUu', remove_accents( 'ƠơƯư' ), 'remove_accents replaces vowels with diacritic' ); |
| 1171 | } |
| 1172 | |
| 1173 | public function test_replaces_grave_accent() { |
| 1174 | $this->assertEquals( 'AaAaEeOoOoUuYy', remove_accents( 'ẦầẰằỀềỒồỜờỪừỲỳ' ), 'remove_accents replaces grave diacritic' ); |
| 1175 | } |
| 1176 | |
| 1177 | public function test_replaces_hook() { |
| 1178 | $this->assertEquals( 'AaAaAaEeEeIiOoOoOoUuUuYy', remove_accents( 'ẢảẨẩẲẳẺẻỂểỈỉỎỏỔổỞởỦủỬửỶỷ' ), 'remove_accents replaces hook diacritic' ); |
| 1179 | } |
| 1180 | |
| 1181 | public function test_replaces_tilde() { |
| 1182 | $this->assertEquals( 'AaAaEeEeOoOoUuYy', remove_accents( 'ẪẫẴẵẼẽỄễỖỗỠỡỮữỸỹ' ), 'remove_accents replaces tilde diacritic' ); |
| 1183 | } |
| 1184 | |
| 1185 | public function test_replaces_acute() { |
| 1186 | $this->assertEquals( 'AaAaEeOoOoUu', remove_accents( 'ẤấẮắẾếỐốỚớỨứ' ), 'remove_accents replaces accute accent' ); |
| 1187 | } |
| 1188 | |
| 1189 | public function test_replaces_dot_below() { |
| 1190 | $this->assertEquals( 'AaAaAaEeEeIiOoOoOoUuUuYy', remove_accents( 'ẠạẬậẶặẸẹỆệỊịỌọỘộỢợỤụỰựỴỵ' ), 'remove_accents replaces dot below' ); |
| 1191 | } |
| 1192 | } |
| 1193 | |