Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed sqlite tests #586

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion manifest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
'label' => 'Generis Core',
'description' => 'Core extension, provide the low level framework and an API to manage ontologies',
'license' => 'GPL-2.0',
'version' => '8.2.1',
'version' => '8.2.3',
'author' => 'Open Assessment Technologies, CRP Henri Tudor',
'requires' => array(),
'models' => array(
Expand Down
2 changes: 1 addition & 1 deletion scripts/update/Updater.php
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,6 @@ public function update($initialVersion)
$this->setVersion('8.0.0');
}

$this->skip('8.0.0', '8.2.1');
$this->skip('8.0.0', '8.2.3');
}
}
9 changes: 8 additions & 1 deletion test/unit/common/persistence/sql/PlatformTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,14 @@

class PlatformTest extends TestCase
{

protected function setUp()
{
if (!extension_loaded('pdo_sqlite')) {
Copy link
Contributor

@alexeyvy alexeyvy Feb 13, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can just use oat\generis\test\TestCase::getSqlMock() inside the test cases below. It does the same (checking the pdo_sqlite is loaded and creating connection). With this approach you don't ever need to have this setUp().

$this->markTestSkipped(
'The PDO SQLITE extension is not available.'
);
}
}
public function testGetQueryBuilder()
{
$platform = $this->createInstance();
Expand Down
9 changes: 8 additions & 1 deletion test/unit/common/persistence/sql/dbal/DriverTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,14 @@
*/
class DriverTest extends TestCase
{

protected function setUp()
{
if (!extension_loaded('pdo_sqlite')) {
$this->markTestSkipped(
'The PDO SQLITE extension is not available.'
);
}
}
public function testGetPlatForm()
{
$driver = new \common_persistence_sql_dbal_Driver();
Expand Down