]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
Extending grammar integration tests (#6644)
authorClint Herron <redacted>
Mon, 29 Apr 2024 18:40:14 +0000 (14:40 -0400)
committerGitHub <redacted>
Mon, 29 Apr 2024 18:40:14 +0000 (14:40 -0400)
commitb8c1476e44cc1f3a1811613f65251cf779067636
treee568647211ef3be479f9273f100645d9aa20bc2e
parent5539e6fdd1b97e0c37c54d34df67f334fc344a26
Extending grammar integration tests (#6644)

* Cleaning up integration tests to share code between tests and make it simpler to add new tests.

* Add tests around quantifiers to ensure both matching and non-matching compliance.

* Add slightly more complex grammar with quantifiers to test references with quantifiers.

* Fixing build when C++17 is not present.

* Separating test calls to give more helpful stack traces on failure. Adding verbose messages to give visibility for what is being tested.

* Adding quotes around strings to explicitly show whitespace

* Removing trailing whitespace.

* Implementing suggestions from @ochafik -- grammars and test strings now print and flush before tests to aid in debugging segfaults and whatnot.

* Cleaning up forgotten symbols. Modifying simple test to use test harness. Added comments for more verbose descriptions of what each test is accomplishing.

* Unicode symbol modifications to hopefully make log easier to parse visually.
tests/test-grammar-integration.cpp