'"Test if the re-authentication only happens once.'

def test_camera_image_reauths_only_once(self):

    self.uvc._camera = mock.MagicMock()
    self.uvc._camera.get_snapshot.side_effect = camera.CameraAuthError
    with mock.patch.object(self.uvc, '_login') as mock_login:
        self.assertRaises(camera.CameraAuthError, self.uvc.camera_image)
        self.assertEqual(mock_login.call_count, 1)
        self.assertEqual(mock_login.call_args, mock.call())
