'Testing a get'

@mock.patch('oc_version.Utils.create_tmpfile_copy')
@mock.patch('oc_version.OCVersion.openshift_cmd')
def test_get(self, mock_openshift_cmd, mock_tmpfile_copy):

    params = {'kubeconfig': '/etc/origin/master/admin.kubeconfig', 'state': 'list', 'debug': False}
    mock_openshift_cmd.side_effect = [{'cmd': 'oc    version', 'results': (((('oc    v3.4.0.39\nkubernetes    v1.4.0+776c994\n' + 'features:    Basic-Auth    GSSAPI    Kerberos    SPNEGO\n\n') + 'Server    https://internal.api.opstest.openshift.com') + 'openshift    v3.4.0.39\n') + 'kubernetes    v1.4.0+776c994\n'), 'returncode': 0}]
    mock_tmpfile_copy.side_effect = ['/tmp/mocked_kubeconfig']
    results = OCVersion.run_ansible(params)
    self.assertFalse(results['changed'])
    self.assertEqual(results['results']['oc_short'], '3.4')
    self.assertEqual(results['results']['oc_numeric'], '3.4.0.39')
    self.assertEqual(results['results']['kubernetes_numeric'], '1.4.0')
