database icon indicating copy to clipboard operation
database copied to clipboard

Feat: toString() for queries

Open Meldiron opened this issue 3 years ago • 0 comments

In Appwrite, we currently test queries by passing string versions into HTTP requests, such as

'queries' => [ 'limit(1)' ]

Thanks to introduction of toString(), we can now build actual query classes in Appwrite tests, such as

'queries' => [ Query::limit(1)->toString() ]

That will improve code quality and will make sure no unexpected test breaks occur when internal change is done to queries syntax.

Meldiron avatar Sep 01 '22 10:09 Meldiron