You verify that the expected result is expected for this entry.
If I understand correctly, your QueryBuilder collects the details of the query, so make sure that the data structure containing these parts actually contains them when you add them through the QueryBuilder method. If he has a method addWhereClauseor something like that, check if this method is really what you entered into the body of the method, for example. write a test for example
public function testWhereMethodAddsExpressionToPartsArray()
{
$expression = 'foo = "bar"';
$this->sut->where($expression);
$parts = $this->sut->getParts('where');
$this->assertContains($expression, $parts);
}
For SqlConstructor, do the same, verify that the input it receives from the data structure filled with QueryBuilder (you may want to mock it) gives the expected result.
SQL, . , UnitTest, SQL, SQLGenerator SQL , , .
SQL - SQL. . ? SQL , .
: