openshift / origin-server

OpenShift 2 (deprecated)
889 stars 516 forks source link

admin_helper.rb: check for nil plans #6348

Closed thrasher-redhat closed 8 years ago

thrasher-redhat commented 8 years ago

Bug 1279584 BZ https://bugzilla.redhat.com/show_bug.cgi?id=1279584

In situations where get_plans() returns nil when trying to determine user capabilities, attempting to populate_user_hash() in oo-admin-chk and oo-admin-repair would result in the script crashing due to an undefined method exception. The script will now check if get_plans() comes back nil and will drop back to using the default user capabilities, as well as displaying a warning that the plan has not been implemented. This warning will not cause oo-admin-chk or oo-admin-repair to fail.

tiwillia commented 8 years ago

LGTM

tiwillia commented 8 years ago

Although there are no tests for oo-admin-chk, it may still be useful to run through the testing suite since this is a change to the controller code.

[test]

openshift-bot commented 8 years ago

Evaluated for online test up to 65f72bd7c6b022a6211c80670c2b40934f0802ec

openshift-bot commented 8 years ago

Online Test Results: SUCCESS (https://ci.dev.openshift.redhat.com/jenkins/job/test_pull_requests/9148/)

tiwillia commented 8 years ago

[merge] please!

openshift-bot commented 8 years ago

Online Merge Results: SUCCESS (https://ci.dev.openshift.redhat.com/jenkins/job/merge_pull_requests/6688/) (Image: devenv_5754)

openshift-bot commented 8 years ago

Evaluated for online merge up to 65f72bd7c6b022a6211c80670c2b40934f0802ec