mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[ticket/12747] Drop support for Firebird
PHPBB3-12747
This commit is contained in:
@@ -145,25 +145,7 @@ abstract class phpbb_database_test_case extends PHPUnit_Extensions_Database_Test
|
||||
|
||||
public function createXMLDataSet($path)
|
||||
{
|
||||
$db_config = $this->get_database_config();
|
||||
|
||||
// Firebird requires table and column names to be uppercase
|
||||
if ($db_config['dbms'] == 'phpbb\db\driver\firebird')
|
||||
{
|
||||
$xml_data = file_get_contents($path);
|
||||
$xml_data = preg_replace_callback('/(?:(<table name="))([a-z_]+)(?:(">))/', 'phpbb_database_test_case::to_upper', $xml_data);
|
||||
$xml_data = preg_replace_callback('/(?:(<column>))([a-z_]+)(?:(<\/column>))/', 'phpbb_database_test_case::to_upper', $xml_data);
|
||||
|
||||
$new_fixture = tmpfile();
|
||||
fwrite($new_fixture, $xml_data);
|
||||
fseek($new_fixture, 0);
|
||||
|
||||
$meta_data = stream_get_meta_data($new_fixture);
|
||||
$path = $meta_data['uri'];
|
||||
}
|
||||
|
||||
$this->fixture_xml_data = parent::createXMLDataSet($path);
|
||||
|
||||
return $this->fixture_xml_data;
|
||||
}
|
||||
|
||||
@@ -246,7 +228,6 @@ abstract class phpbb_database_test_case extends PHPUnit_Extensions_Database_Test
|
||||
|
||||
/**
|
||||
* Converts a match in the middle of a string to uppercase.
|
||||
* This is necessary for transforming the fixture information for Firebird tests
|
||||
*
|
||||
* @param $matches The array of matches from a regular expression
|
||||
*
|
||||
|
Reference in New Issue
Block a user