Add an assert and a test that verify r221709's fix.