'Test switch_info fails.'

def test_switch_info_no_switch(self):

    module = Mock()
    module.params = dict(switch_name='eos')
    module.client.api.get_device_by_name.return_value = None
    info = cv_server_provision.switch_info(module)
    self.assertEqual(module.client.api.get_device_by_name.call_count, 1)
    self.assertEqual(info, None)
    module.fail_json.assert_called_once_with(msg="Device    with    name    'eos'    does    not    exist.")
