Disallow empty tags in test case specification

This commit is contained in:
Martin Hořeňovský
2021-05-28 20:49:05 +02:00
parent c9371865d4
commit aee31d0620
11 changed files with 48 additions and 10 deletions

View File

@@ -146,6 +146,7 @@ namespace Catch {
// it over to backing storage and actually reference the
// backing storage in the saved tags
StringRef tagStr = originalTags.substr(tagStart+1, tagEnd - tagStart - 1);
CATCH_ENFORCE(!tagStr.empty(), "Empty tags are not allowed");
enforceNotReservedTag(tagStr, lineInfo);
properties |= parseSpecialTag(tagStr);
// When copying a tag to the backing storage, we need to