blob: 3fc60f92709d5d12ffdd0ac5e55656b9555501ec [file] [log] [blame]
############################################################################
# Copyright (C) SchedMD LLC.
############################################################################
import atf
import re
def test_usage():
"""Verify salloc --usage has the correct format"""
output = atf.run_command_output("salloc --usage", fatal=True)
assert (
re.search(
r"Usage: salloc(?:\s+\[{1,2}-{1,2}.*?\](?=\s+\[))+\s+\[command \[args\.\.\.\]\]$",
output,
)
is not None
)