add new check_deprecated context manager for version check, use mark.parametrize from pytest for observer deprecation tests