Fix 2 OS examples

This commit is contained in:
Timothyxxx
2024-02-06 23:56:53 +08:00
parent df5594b645
commit f162acbbe3
2 changed files with 55 additions and 12 deletions

View File

@@ -17,17 +17,29 @@
"os"
],
"evaluator": {
"func": "exact_match",
"postconfig": [
{
"type": "sleep",
"parameters": {
"seconds": 5
}
}
],
"func": "check_include_exclude",
"result": {
"type": "vm_command_line",
"command": "[[ -z $(ps -ef | grep -v grep | grep my_process) ]] && echo \"Process killed\" || echo \"Process still running\"",
"command": "ps -ef | grep my_process.sh",
"shell": true
},
"expected": {
"type": "rule",
"rules":{
"expected": "Process killed"
}
"type": "rule",
"rules": {
"include": [
],
"exclude": [
"/bin/sh ./my_process.sh"
]
}
}
}
}