could we add a test for this bug by verifying the output?