Sha goodie: allow some noise in query before string, amend tests