Add regression test for #14244.

Refs #14244.
CC: @programcsharp