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
c880b19e
Commit
c880b19e
authored
Sep 06, 2015
by
Tobias Schultze
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add unit tests for deadlock errors
parent
224b76e1
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
0 deletions
+18
-0
AbstractDriverTest.php
tests/Doctrine/Tests/DBAL/Driver/AbstractDriverTest.php
+2
-0
AbstractMySQLDriverTest.php
tests/Doctrine/Tests/DBAL/Driver/AbstractMySQLDriverTest.php
+6
-0
AbstractPostgreSQLDriverTest.php
...ctrine/Tests/DBAL/Driver/AbstractPostgreSQLDriverTest.php
+4
-0
AbstractSQLAnywhereDriverTest.php
...trine/Tests/DBAL/Driver/AbstractSQLAnywhereDriverTest.php
+3
-0
AbstractSQLiteDriverTest.php
...s/Doctrine/Tests/DBAL/Driver/AbstractSQLiteDriverTest.php
+3
-0
No files found.
tests/Doctrine/Tests/DBAL/Driver/AbstractDriverTest.php
View file @
c880b19e
...
...
@@ -24,6 +24,8 @@ abstract class AbstractDriverTest extends DbalTestCase
const
EXCEPTION_TABLE_EXISTS
=
'Doctrine\DBAL\Exception\TableExistsException'
;
const
EXCEPTION_TABLE_NOT_FOUND
=
'Doctrine\DBAL\Exception\TableNotFoundException'
;
const
EXCEPTION_UNIQUE_CONSTRAINT_VIOLATION
=
'Doctrine\DBAL\Exception\UniqueConstraintViolationException'
;
const
EXCEPTION_DEADLOCK
=
'Doctrine\DBAL\Exception\DeadlockException'
;
const
EXCEPTION_LOCK_WAIT_TIMEOUT
=
'Doctrine\DBAL\Exception\LockWaitTimeoutException'
;
/**
* The driver mock under test.
...
...
tests/Doctrine/Tests/DBAL/Driver/AbstractMySQLDriverTest.php
View file @
c880b19e
...
...
@@ -134,6 +134,12 @@ class AbstractMySQLDriverTest extends AbstractDriverTest
array
(
'1569'
,
null
,
null
),
array
(
'1586'
,
null
,
null
),
),
self
::
EXCEPTION_DEADLOCK
=>
array
(
array
(
'1213'
,
null
,
null
),
),
self
::
EXCEPTION_LOCK_WAIT_TIMEOUT
=>
array
(
array
(
'1205'
,
null
,
null
),
),
);
}
}
tests/Doctrine/Tests/DBAL/Driver/AbstractPostgreSQLDriverTest.php
View file @
c880b19e
...
...
@@ -101,6 +101,10 @@ class AbstractPostgreSQLDriverTest extends AbstractDriverTest
self
::
EXCEPTION_UNIQUE_CONSTRAINT_VIOLATION
=>
array
(
array
(
null
,
'23505'
,
null
),
),
self
::
EXCEPTION_DEADLOCK
=>
array
(
array
(
null
,
'40001'
,
null
),
array
(
null
,
'40P01'
,
null
),
),
);
}
}
tests/Doctrine/Tests/DBAL/Driver/AbstractSQLAnywhereDriverTest.php
View file @
c880b19e
...
...
@@ -93,6 +93,9 @@ class AbstractSQLAnywhereDriverTest extends AbstractDriverTest
array
(
'-193'
,
null
,
null
),
array
(
'-196'
,
null
,
null
),
),
self
::
EXCEPTION_DEADLOCK
=>
array
(
array
(
'-306'
,
null
,
null
),
),
);
}
}
tests/Doctrine/Tests/DBAL/Driver/AbstractSQLiteDriverTest.php
View file @
c880b19e
...
...
@@ -73,6 +73,9 @@ class AbstractSQLiteDriverTest extends AbstractDriverTest
array
(
null
,
null
,
'is not unique'
),
array
(
null
,
null
,
'are not unique'
),
),
self
::
EXCEPTION_LOCK_WAIT_TIMEOUT
=>
array
(
array
(
null
,
null
,
'database is locked'
),
),
);
}
}
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