Fixed bad YAML in REST tests

This commit is contained in:
Clinton Gormley 2016-03-03 13:33:53 +01:00
parent c996db731a
commit ce7fccb287
1 changed files with 12 additions and 6 deletions

View File

@ -20,12 +20,14 @@
"Test cat nodes attrs output": "Test cat nodes attrs output":
- do: - do:
cat.nodeattrs: {} cat.nodeattrs: {}
- match: # All attributes look good # All attributes look good
- match:
$body: | $body: |
/^# node\s+ host\s+ ip\s+ attr\s+ value\s* \n /^# node\s+ host\s+ ip\s+ attr\s+ value\s* \n
(((\S+\s?){1,10})\s+(\S+)\s+(\d{1,3}\.){3}\d{1,3}\s+(\S+)\s+ (\S+)\s* \n)+ (((\S+\s?){1,10})\s+(\S+)\s+(\d{1,3}\.){3}\d{1,3}\s+(\S+)\s+ (\S+)\s* \n)+
$/ $/
- match: # A specific planted attribute is present and looks good # A specific planted attribute is present and looks good
- match:
$body: | $body: |
/# node\s+ host\s+ ip\s+ attr\s+ value\s* \n /# node\s+ host\s+ ip\s+ attr\s+ value\s* \n
(\S+(\s\S+){0,7})\s+ (\S+)\s+ (\d{1,3}\.){3}\d{1,3}\s+testattr\s+ test \s* \n (\S+(\s\S+){0,7})\s+ (\S+)\s+ (\d{1,3}\.){3}\d{1,3}\s+testattr\s+ test \s* \n
@ -37,12 +39,14 @@
- do: - do:
cat.nodeattrs: cat.nodeattrs:
v: true v: true
- match: # All attributes look good including the heading # All attributes look good including the heading
- match:
$body: | $body: |
/^ node\s+ host\s+ ip\s+ attr\s+ value\s* \n /^ node\s+ host\s+ ip\s+ attr\s+ value\s* \n
(((\S+\s?){1,10})\s+(\S+)\s+(\d{1,3}\.){3}\d{1,3}\s+(\S+)\s+ (\S+)\s* \n)+ (((\S+\s?){1,10})\s+(\S+)\s+(\d{1,3}\.){3}\d{1,3}\s+(\S+)\s+ (\S+)\s* \n)+
$/ $/
- match: # A specific planted attribute is present and looks good # A specific planted attribute is present and looks good
- match:
$body: | $body: |
/# node\s+ host\s+ ip\s+ attr\s+ value\s* \n /# node\s+ host\s+ ip\s+ attr\s+ value\s* \n
(\S+(\s\S+){0,7})\s+ (\S+)\s+ (\d{1,3}\.){3}\d{1,3}\s+ testattr\s+ test \s* \n (\S+(\s\S+){0,7})\s+ (\S+)\s+ (\d{1,3}\.){3}\d{1,3}\s+ testattr\s+ test \s* \n
@ -52,12 +56,14 @@
cat.nodeattrs: cat.nodeattrs:
h: attr,value h: attr,value
v: true v: true
- match: # All attributes look good # All attributes look good
- match:
$body: | $body: |
/^ attr\s+ value\s*\n /^ attr\s+ value\s*\n
((\S+)\s+ (\S+)\s*)+ ((\S+)\s+ (\S+)\s*)+
$/ $/
- match: # A specific planted attribute is present and looks good # A specific planted attribute is present and looks good
- match:
$body: | $body: |
/# attr\s+ value\s*\n /# attr\s+ value\s*\n
testattr\s+ test\s*\n testattr\s+ test\s*\n