filter out non-unicode codepoints and add test