@@ -283,6 +283,12 @@ public function testMiscellaneous()
283283 $ query = $ this ->createHelper ()->showDatabases ();
284284 $ this ->assertEquals ('SHOW DATABASES ' , $ query ->compile ()->getCompiled ());
285285
286+ $ query = $ this ->createHelper ()->showCharacterSet ();
287+ $ this ->assertEquals ('SHOW CHARACTER SET ' , $ query ->compile ()->getCompiled ());
288+
289+ $ query = $ this ->createHelper ()->showCollation ();
290+ $ this ->assertEquals ('SHOW COLLATION ' , $ query ->compile ()->getCompiled ());
291+
286292 $ query = $ this ->createHelper ()->showCreateTable ('rt ' );
287293 $ this ->assertEquals ('SHOW CREATE TABLE rt ' , $ query ->compile ()->getCompiled ());
288294
@@ -432,6 +438,11 @@ public function testCapabilitiesAndSupports()
432438 $ this ->assertNotEmpty ($ caps ->getEngine ());
433439 $ this ->assertTrue ($ this ->createHelper ()->supports ('grouped_where ' ));
434440 $ this ->assertIsBool ($ this ->createHelper ()->supports ('show_profile ' ));
441+ $ this ->assertIsBool ($ this ->createHelper ()->supports ('show_character_set ' ));
442+ $ this ->assertIsBool ($ this ->createHelper ()->supports ('show_collation ' ));
443+ $ this ->assertSame ($ caps ->isManticore (), $ caps ->getEngine () === 'MANTICORE ' );
444+ $ this ->assertSame ($ caps ->isSphinx2 (), $ caps ->getEngine () === 'SPHINX2 ' );
445+ $ this ->assertSame ($ caps ->isSphinx3 (), $ caps ->getEngine () === 'SPHINX3 ' );
435446 }
436447
437448 public function testSupportsUnknownFeatureValidation ()
@@ -473,6 +484,26 @@ public function testShowPluginsExecutionWhenSupported()
473484 $ this ->assertIsArray ($ rows );
474485 }
475486
487+ public function testShowCharacterSetExecutionWhenSupported ()
488+ {
489+ if (!TestUtil::supportsCommand ($ this ->conn , 'SHOW CHARACTER SET ' )) {
490+ $ this ->markTestSkipped ('SHOW CHARACTER SET is not supported by this engine. ' );
491+ }
492+
493+ $ rows = $ this ->createHelper ()->showCharacterSet ()->execute ()->getStored ();
494+ $ this ->assertIsArray ($ rows );
495+ }
496+
497+ public function testShowCollationExecutionWhenSupported ()
498+ {
499+ if (!TestUtil::supportsCommand ($ this ->conn , 'SHOW COLLATION ' )) {
500+ $ this ->markTestSkipped ('SHOW COLLATION is not supported by this engine. ' );
501+ }
502+
503+ $ rows = $ this ->createHelper ()->showCollation ()->execute ()->getStored ();
504+ $ this ->assertIsArray ($ rows );
505+ }
506+
476507 public function testSuggestExecutionWhenSupported ()
477508 {
478509 if (!TestUtil::supportsCommand ($ this ->conn , "CALL SUGGEST('teh', 'rt') " )) {
0 commit comments