egeldenhuys / black-fitch

[DEPRECATED] Black-box Unit Tests for Fitchfork practicals and assignments
GNU General Public License v3.0
8 stars 4 forks source link

Suggestion: Use regex for string matching #8

Closed devosray closed 8 years ago

devosray commented 8 years ago

From issue #7 it seems like Fitch-fork does not always check the output character by character. Maybe we could rather use regex to parse the output string so we can optionally check for characters?

The check referred to by issue #7 could be replaced by the following regex expression: "Inventory of (libraryName):?\n"

C++11 has a built in regex library so it is definitely doable

egeldenhuys commented 8 years ago

Will make use of regex for future tests where fitchfork is not so strict on the output. For example when it simply looks for a certain string in the output.

Thank you for the regex links.