Skip to content

Commit

Permalink
Merge 7709220 into 284559f
Browse files Browse the repository at this point in the history
  • Loading branch information
KorayKirli committed Apr 29, 2019
2 parents 284559f + 7709220 commit 0fab344
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
6 changes: 6 additions & 0 deletions chalicelib/check_setup.json
Original file line number Diff line number Diff line change
Expand Up @@ -775,6 +775,12 @@
}
}
},
"say_my_name": {
"title": "Say my name",
"group": "System checks",
"schedule": {},
"display": ["data"]
},
"users_with_pending_lab": {
"title": "Users with Pending Lab",
"group": "Metadata checks",
Expand Down
24 changes: 24 additions & 0 deletions chalicelib/checks/system_checks.py
Original file line number Diff line number Diff line change
Expand Up @@ -776,3 +776,27 @@ def check_long_running_ec2s(connection, **kwargs):
check.status = 'PASS'
check.summary = '%s EC2s running longer than 1 week' % (len(check.full_output))
return check


@check_function(FS_dev='free', FF_hotseat='free', FF_mastertest='free', FF_webdev='free')
def say_my_name(connection, **kwargs):
"""List the person working on each environment."""
check = init_check_res(connection, 'say_my_name')
check.description = "Enter the new name or if you are done, use 'free' to clear your name"
check.summary = ""
check.brief_output = ""
check.status = "PASS"
output = {}
# update with the new parameters ()
for a_key in ['FS_dev', 'FF_hotseat', 'FF_mastertest', 'FF_webdev']:
if kwargs.get(a_key):
val = kwargs[a_key]
if val.lower() == 'free':
val = 'free'
output[a_key] = val
else:
output[a_key] = 'free'
sum = str(output)[1:-1].replace("'", "")
check.summary = sum
check.brief_output = sum
return check

0 comments on commit 0fab344

Please sign in to comment.