Add nil condition to fix
What does this MR do and why?
Add nil condition to fix the JH broken pipeline see https://gitlab.com/gitlab-jh/gitlab/-/jobs/1856297307#L484
Since some test examples need to skip.
Related JH MR
@godfat-gitlab Could you please help review this, thanks. This break pipeline of JH.