Support ✓/✗ as alternatives to [success]/[failure]
This commit is contained in:
parent
4704cc088d
commit
0719fa33c2
3 changed files with 49 additions and 21 deletions
|
|
@ -91,10 +91,10 @@ for commit_hash in "${commits[@]}"; do
|
|||
if not line.strip():
|
||||
continue
|
||||
|
||||
match = re.match(r"^\\[(success|failure)\\]\\s+(.+)$", line)
|
||||
match = re.match(r"^(\\[success\\]|\\[failure\\]|✓|✗)\\s+(.+)$", line)
|
||||
if match:
|
||||
current_step = {
|
||||
"expects_success": match.group(1) == "success",
|
||||
"expects_success": match.group(1) in ("[success]", "✓"),
|
||||
"command": match.group(2),
|
||||
"assertions": [],
|
||||
}
|
||||
|
|
@ -104,7 +104,7 @@ for commit_hash in "${commits[@]}"; do
|
|||
if current_step is None:
|
||||
print(
|
||||
f"DSL parse error on line {line_number}: "
|
||||
"assertion text must follow [success] or [failure]."
|
||||
"assertion text must follow [success], [failure], ✓, or ✗."
|
||||
)
|
||||
sys.exit(1)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue