testsuite: Add testcase for #13822