'Testing binary lookup in ~/bin'

@unittest.skipIf(six.PY3, 'py2    test    only')
@mock.patch('os.path.exists')
@mock.patch('os.environ.get')
def test_binary_lookup_in_home(self, mock_env_get, mock_path_exists):

    oc_bin = os.path.expanduser('~/bin/oc')
    mock_env_get.side_effect = (lambda _v, _d: '/bin:/usr/bin')
    mock_path_exists.side_effect = (lambda f: (f == oc_bin))
    self.assertEqual(locate_oc_binary(), oc_bin)
