[Gravity] add SQLiteConnection class
Review Request #83 — Created April 16, 2013 and discarded
Information | |
---|---|
dinos | |
Lunr | |
dinostheo:SQLiteConnection | |
Reviewers | |
lunr | |
Here is the first step of the implementation of SQL lite. the class for query result and query builder will follow. This depends on http://reviews.lunr.nl/r/94/
unit tests
- 7
- 0
- 11
- 0
- 18
Description | From | Last Updated |
---|---|---|
We will need a SQLite3 wrapper class in order to avoid the connect on construct issue. | pprkut | |
How do you unit test this? | pprkut | |
superfluous | pprkut | |
There's just way too many uncertainties about this test. How do you ensure that connect() will always work? | pprkut | |
escape_string, when not connected, will try to connect. Yet, this is not reflected in this test. | pprkut | |
Why not Mock the SQlite3 class? | pprkut | |
?here does $this->logger come from? | pprkut |
Change Summary:
Rebased against pprkut/gravity SQLiteConnection class moved to Gravity/Database/SQLite namespace
Diff: |
Revision 2 (+264) |
---|
-
-
-
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 3) keep this compatible with the mysql connection
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 3) that looks like a very weird key to use
-
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 3) you need to make sure this actually makes sense for sqlite
-
-
-
There's a lot of issues solved but no new revision. Please only close issues when posting a new revision.
Change Summary:
Update according to dinos review for delimiter.
Description: |
|
||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 4 (+269) |
-
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 4) nitpick. You are trying to do the right thing, but you are drawing the wrong conclusion. In order to avoid the line length limit it would make much more sense to reduce the number of function calls than just introduce a (pointless) placeholder variable
-
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 4) you can't instantiate an interface....
Change Summary:
Remove use of configuration: The file is already given to the SQlite3 object The driver can cause issue if concurrent use with other DB
Summary: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 5 (+249) |
Change Summary:
change made according to review. the connection is considered connected from the start
Diff: |
Revision 6 (+281 -4) |
---|
Change Summary:
Change made acccording to reveiw the coneection is considered open from the start
Diff: |
Revision 7 (+263) |
---|
Change Summary:
Added unit tests to the SQLiteConnection class of Olivier. 2 functions from this class are not tested due to their dependency to query builder, get_new_dml_query_builder_object & query.
-
-
src/Lunr/Gravity/Database/SQLite/SQLiteConnection.php (Diff revision 8) We will need a SQLite3 wrapper class in order to avoid the connect on construct issue.
-
-
-
src/Lunr/Gravity/Database/SQLite/Tests/SQLiteConnectionConnectTest.php (Diff revision 8) There's just way too many uncertainties about this test. How do you ensure that connect() will always work?
-
src/Lunr/Gravity/Database/SQLite/Tests/SQLiteConnectionEscapeTest.php (Diff revision 8) escape_string, when not connected, will try to connect. Yet, this is not reflected in this test.
-
src/Lunr/Gravity/Database/SQLite/Tests/SQLiteConnectionTest.php (Diff revision 8) Why not Mock the SQlite3 class?
-
src/Lunr/Gravity/Database/SQLite/Tests/SQLiteConnectionTest.php (Diff revision 8) ?here does $this->logger come from?