public static function setUpBeforeClass()
 {
     if (defined('PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST')) {
         $configuration = new MySQLSchemalessConfiguration();
         $configuration->initDatabase(PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_DBNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_USERNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_PASSWORD);
         $configuration->setCMDLFolder(__DIR__ . '/../../resources/ContentArchiveExample1/cmdl');
         $configuration->setRepositoryName('phpunit');
         $configuration->addContentTypes();
         $database = $configuration->getDatabase();
         $database->execute('DROP TABLE IF EXISTS _cmdl_');
         $database->execute('DROP TABLE IF EXISTS _counter_');
         $database->execute('DROP TABLE IF EXISTS phpunit$profiles');
         $connection = $configuration->createReadWriteConnection();
         $repository = new Repository('phpunit', $connection);
         $repository->selectContentType('profiles');
         $record = $repository->createRecord('dmc digital media center', 5);
         $repository->saveRecord($record);
         $record = $repository->createRecord('Agency 16', 16);
         $repository->saveRecord($record);
         $repository->selectWorkspace('live');
         $record = $repository->createRecord('dmc digital media center', 5);
         $repository->saveRecord($record);
         $repository->selectLanguage('de');
         $record = $repository->createRecord('dmc digital media center', 5);
         $repository->saveRecord($record);
         KVMLoggerFactory::createWithKLogger(__DIR__ . '/../../../tmp');
     }
 }
 public static function setUpBeforeClass()
 {
     if (defined('PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST')) {
         $configuration = new MySQLSchemalessConfiguration();
         $configuration->initDatabase(PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_DBNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_USERNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_PASSWORD);
         $configuration->setRepositoryName('phpunit');
         $database = $configuration->getDatabase();
         $database->execute('DROP TABLE IF EXISTS _cmdl_');
         $database->execute('DROP TABLE IF EXISTS _counter_');
         $database->execute('DROP TABLE IF EXISTS phpunit$profiles');
         $connection = $configuration->createReadWriteConnection();
         KVMLoggerFactory::createWithKLogger(__DIR__ . '/../../../tmp');
     }
 }
 public static function setUpBeforeClass()
 {
     if (defined('PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST')) {
         $configuration = new MySQLSchemalessConfiguration();
         $configuration->initDatabase(PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_DBNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_USERNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_PASSWORD);
         $configuration->setCMDLFolder(__DIR__ . '/../../resources/ContentArchiveExample1/cmdl');
         $configuration->addContentTypes('phpunit');
         $database = $configuration->getDatabase();
         $database->execute('DROP TABLE IF EXISTS _cmdl_');
         $database->execute('DROP TABLE IF EXISTS _counter_');
         $database->execute('DROP TABLE IF EXISTS phpunit$profiles');
         KVMLoggerFactory::createWithKLogger(__DIR__ . '/../../../tmp');
     }
 }
 public static function setUpBeforeClass()
 {
     if (defined('PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST')) {
         $source = __DIR__ . '/../../resources/ContentArchiveExample1/cmdl';
         $target = __DIR__ . '/../../../tmp/MySqlSchemaLessCMDL';
         $fs = new Filesystem();
         if (file_exists($target)) {
             $fs->remove($target);
         }
         $fs->mirror($source, $target);
         $configuration = new MySQLSchemalessConfiguration();
         $configuration->initDatabase(PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_HOST, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_DBNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_USERNAME, PHPUNIT_CREDENTIALS_MYSQL_SCHEMALESS_PASSWORD);
         $configuration->setCMDLFolder($target);
         $configuration->setRepositoryName('phpunit');
         $configuration->addContentTypes();
         $database = $configuration->getDatabase();
         $database->execute('DROP TABLE IF EXISTS _cmdl_');
         $database->execute('DROP TABLE IF EXISTS _counter_');
         $database->execute('DROP TABLE IF EXISTS phpunit$profiles');
         $connection = $configuration->createReadWriteConnection();
         $repository = new Repository('phpunit', $connection);
         $repository->selectContentType('profiles');
         $record = $repository->createRecord('Agency 1', 1);
         $repository->saveRecord($record);
         $record = $repository->createRecord('Agency 2', 2);
         $repository->saveRecord($record);
         $record = $repository->createRecord('Agency 5', 5);
         $repository->saveRecord($record);
         $repository->selectWorkspace('live');
         $record = $repository->createRecord('Agency 1', 1);
         $repository->saveRecord($record);
         $record = $repository->createRecord('Agency 2', 2);
         $repository->saveRecord($record);
         KVMLoggerFactory::createWithKLogger(__DIR__ . '/../../../tmp');
     }
 }