[WIP] alter table
Currently a WIP pull request so I have a clear overview of the changes I have made so far
Pull Request Test Coverage Report for Build 10479540308
Details
- 0 of 0 changed or added relevant lines in 0 files are covered.
- No unchanged relevant lines lost coverage.
- Overall coverage decreased (-0.3%) to 79.642%
| Totals | |
|---|---|
| Change from base Build 10466756119: | -0.3% |
| Covered Lines: | 4268 |
| Relevant Lines: | 5359 |
💛 - Coveralls
One point of feedback: I wouldn't test on the generated text. Rather I'd execute the query into a clean DB to make sure it actually works. It's a much more robust test that doesn't fail when we make formatting changes to our queries. Here's an example: https://github.com/tempestphp/tempest-framework/blob/query-statement-defaults/tests/Integration/Database/QueryStatements/CreateTableStatementTest.php
One point of feedback: I wouldn't test on the generated text. Rather I'd execute the query into a clean DB to make sure it actually works.
Oh I like that, good idea
One point of feedback: I wouldn't test on the generated text. Rather I'd execute the query into a clean DB to make sure it actually works. It's a much more robust test that doesn't fail when we make formatting changes to our queries. Here's an example:
query-statement-defaults/tests/Integration/Database/QueryStatements/CreateTableStatementTest.php
@brendt just made a test like this, can't use the word table as table name 😋
You can use table if you wrap it in backticks ;)
You can use
tableif you wrap it in backticks ;)
True, 😅 though personally I'm not very fond of backticks in programming. I remember something about eval(..) in PHP 😋
No but it should be within the compiled query, check out the CreateTableStatement where I added it as well ;)
Gonna merge this one in a separate branch and work on a bit more