A more rigorous battery of tests for the q_str macro

(and fixes based on those tests)