Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
e4c143f0
Commit
e4c143f0
authored
Jul 15, 2016
by
Steve Müller
Committed by
GitHub
Jul 15, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #911 from Tobion/fix-tests-on-windows
fix dbal tests on windows
parents
b6b247a3
00b3eaed
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
ExceptionTest.php
tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php
+4
-2
SqliteSchemaManagerTest.php
.../Tests/DBAL/Functional/Schema/SqliteSchemaManagerTest.php
+4
-0
No files found.
tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php
View file @
e4c143f0
...
...
@@ -286,9 +286,10 @@ class ExceptionTest extends \Doctrine\Tests\DbalFunctionalTestCase
$this
->
markTestSkipped
(
"Only fails this way on sqlite"
);
}
$filename
=
sprintf
(
'%s/%s'
,
sys_get_temp_dir
(),
'doctrine_failed_connection.db'
);
$filename
=
sprintf
(
'%s/%s'
,
sys_get_temp_dir
(),
'doctrine_failed_connection
_'
.
$mode
.
'
.db'
);
if
(
file_exists
(
$filename
))
{
chmod
(
$filename
,
0200
);
// make the file writable again, so it can be removed on Windows
unlink
(
$filename
);
}
...
...
@@ -314,7 +315,8 @@ class ExceptionTest extends \Doctrine\Tests\DbalFunctionalTestCase
public
function
getSqLiteOpenConnection
()
{
return
array
(
array
(
0000
,
'\Doctrine\DBAL\Exception\ConnectionException'
),
// mode 0 is considered read-only on Windows
array
(
0000
,
defined
(
'PHP_WINDOWS_VERSION_BUILD'
)
?
'\Doctrine\DBAL\Exception\ReadOnlyException'
:
'\Doctrine\DBAL\Exception\ConnectionException'
),
array
(
0444
,
'\Doctrine\DBAL\Exception\ReadOnlyException'
),
);
}
...
...
tests/Doctrine/Tests/DBAL/Functional/Schema/SqliteSchemaManagerTest.php
View file @
e4c143f0
...
...
@@ -136,6 +136,10 @@ EOS
public
function
testNonDefaultPKOrder
()
{
if
(
!
extension_loaded
(
'sqlite3'
))
{
$this
->
markTestSkipped
(
'This test requires the SQLite3 extension.'
);
}
$version
=
\SQLite3
::
version
();
if
(
version_compare
(
$version
[
'versionString'
],
'3.7.16'
,
'<'
))
{
$this
->
markTestSkipped
(
'This version of sqlite doesn\'t return the order of the Primary Key.'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment