Support DateTime instances
Support for the time type with test coverage will be added after review of #230
| Q | A |
|---|---|
| Is bugfix? | ❌ |
| New feature? | ✔️ |
| Breaks BC? | ✔️ |
| Fixed issues | #725 |
PR Summary
-
Enhanced
ColumnSchemaclass with a new method This change introduces aphpTypecastmethod to theColumnSchemaclass, paving the way for a more versatile use of the class in different scenarios. -
Enhanced
Connectionclass We've added a new methodinitConnectionto theConnectionclass. This would help in setting up the initial configurations for the database connection with ease. -
Advanced datetime handling Through the addition of
getDateTimeFormatin theSchemaclass and modifying thecreateColumnSchemamethod, we're now more adept in handling time and date data types. ThenormalizeDefaultValuemodification further optimizes how we handle default values for timestamps. -
Improved testing We're enforcing code quality and reliability by introducing new tests to
ColumnSchemaTestandSchemaProvider. These additions ensure our methods for handling different column types and their attributes are thoroughly checked. -
Updated SQL fixture The
oci.sqlfixture file has seen changes, too, to support columns with different default values for timestamps and dates. This change makes our test data align better with the real-world scenarios.
Codecov Report
Patch coverage: 97.05% and project coverage change: -0.08% :warning:
Comparison is base (
744eb43) 98.29% compared to head (1269d82) 98.21%. Report is 2 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #231 +/- ##
============================================
- Coverage 98.29% 98.21% -0.08%
- Complexity 186 194 +8
============================================
Files 16 16
Lines 585 617 +32
============================================
+ Hits 575 606 +31
- Misses 10 11 +1
| Files Changed | Coverage Δ | |
|---|---|---|
| src/ColumnSchema.php | 92.85% <83.33%> (-7.15%) |
:arrow_down: |
| src/Connection.php | 97.22% <100.00%> (+0.55%) |
:arrow_up: |
| src/Schema.php | 100.00% <100.00%> (ø) |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Need restore code coverage
Yes, mentioned about this in the description:
Support for the
timetype with test coverage will be added after review of #230