ARMmbed / htrun

MOVED: https://github.com/ARMmbed/mbed-os-tools (Flash, reset and run host supervised tests on mbed platforms)
8 stars 37 forks source link

Handle regex exception when comparing log #146

Closed mazimkhan closed 7 years ago

mazimkhan commented 7 years ago

Lines from template log are first matched literally and then as regex. In failure cases a line that is expected to match literally will not match and be tried as a regex patter. If the line has unqualified regex it may raise exception. Hence regex exception should be handled as a possibility and match() function should return False (no match) on exception.

@bridadan @adbridge Please review.

adbridge commented 7 years ago

@mazimkhan merge commits onto PRs are frowned upon (certainly for mbed-os) code as it makes patching hard. A rebase and force push would have been better....

mazimkhan commented 7 years ago

@adbridge Done.