Compliance cases

These are the 7,246 inputs a submission must answer. A conforming implementation returns true for the 2,791 valid ones and false for the 4,455 invalid ones. You can run the suite without reading it, or open any case to see its input and where its first ill-formed byte is.

Well-formed means Table 3-7 of the Unicode Standard, as RFC 3629 restates it: no overlong forms, surrogates, code points above U+10FFFF, stray continuation bytes or sequences cut short. The compliance suite combines Markus Kuhn's UTF-8 stress test, WPT's fatal TextDecoder tests, every lead byte against the edges of its allowed ranges, errors at every offset around 16-, 32- and 64-byte blocks and at the end of every length up to 130 bytes, large inputs, and seeded random text. simdutf, Python and a Table 3-7 reference agree on every answer.

Run the full compliance suite locally. Replace your-component.wasm with your compiled component. Download the suite

curl -fLo validate_utf8.comply.wasm https://calculated.world/comply/validate_utf8.wasm
npx qipok your-component.wasm --suite validate_utf8.comply.wasm
Clear

188 of 7,246 cases · 130 true · 58 false

Case Name Expected Note Size
005845 generated/0540 Generated true Seeded random text, mutation: flip bit. 361 B
005861 generated/0556 Generated false Seeded random text, mutation: flip bit. 78 B
005881 generated/0577 Generated false Seeded random text, mutation: flip bit. 4 B
005886 generated/0582 Generated true Seeded random text, mutation: flip bit. 23 B
005888 generated/0584 Generated true Seeded random text, mutation: flip bit. 24 B
005902 generated/0598 Generated false Seeded random text, mutation: flip bit. 28 B
005913 generated/0610 Generated true Seeded random text, mutation: flip bit. 64 B
005917 generated/0614 Generated true Seeded random text, mutation: flip bit. 302 B
005919 generated/0616 Generated true Seeded random text, mutation: flip bit. 183 B
005931 generated/0629 Generated true Seeded random text, mutation: flip bit. 51 B
005939 generated/0637 Generated false Seeded random text, mutation: flip bit. 153 B
005948 generated/0647 Generated true Seeded random text, mutation: flip bit. 5 B
005959 generated/0660 Generated true Seeded random text, mutation: flip bit. 7 B
005971 generated/0672 Generated false Seeded random text, mutation: flip bit. 4 B
005988 generated/0689 Generated true Seeded random text, mutation: flip bit. 27 B
006002 generated/0703 Generated true Seeded random text, mutation: flip bit. 17 B
006013 generated/0714 Generated false Seeded random text, mutation: flip bit. 27 B
006017 generated/0718 Generated true Seeded random text, mutation: flip bit. 25 B
006023 generated/0725 Generated false Seeded random text, mutation: flip bit. 50 B
006025 generated/0727 Generated true Seeded random text, mutation: flip bit. 186 B
006037 generated/0739 Generated true Seeded random text, mutation: flip bit. 8 B
006041 generated/0743 Generated false Seeded random text, mutation: flip bit. 51 B
006042 generated/0744 Generated false Seeded random text, mutation: flip bit. 7 B
006044 generated/0748 Generated true Seeded random text, mutation: flip bit. 18 B
006055 generated/0759 Generated true Seeded random text, mutation: flip bit. 60 B
006059 generated/0763 Generated false Seeded random text, mutation: flip bit. 20 B
006063 generated/0767 Generated true Seeded random text, mutation: flip bit. 82 B
006067 generated/0771 Generated true Seeded random text, mutation: flip bit. 64 B
006076 generated/0780 Generated true Seeded random text, mutation: flip bit. 14 B
006083 generated/0787 Generated true Seeded random text, mutation: flip bit. 59 B
006089 generated/0793 Generated false Seeded random text, mutation: flip bit. 23 B
006118 generated/0823 Generated true Seeded random text, mutation: flip bit. 377 B
006123 generated/0828 Generated true Seeded random text, mutation: flip bit. 13 B
006125 generated/0830 Generated true Seeded random text, mutation: flip bit. 60 B
006138 generated/0846 Generated false Seeded random text, mutation: flip bit. 60 B
006142 generated/0851 Generated true Seeded random text, mutation: flip bit. 74 B
006155 generated/0865 Generated false Seeded random text, mutation: flip bit. 12 B
006159 generated/0870 Generated true Seeded random text, mutation: flip bit. 6 B
006174 generated/0885 Generated true Seeded random text, mutation: flip bit. 10 B
006177 generated/0888 Generated true Seeded random text, mutation: flip bit. 8 B
006189 generated/0900 Generated true Seeded random text, mutation: flip bit. 183 B
006193 generated/0904 Generated true Seeded random text, mutation: flip bit. 108 B
006198 generated/0909 Generated true Seeded random text, mutation: flip bit. 18 B
006201 generated/0912 Generated true Seeded random text, mutation: flip bit. 27 B
006213 generated/0924 Generated false Seeded random text, mutation: flip bit. 47 B
006217 generated/0928 Generated true Seeded random text, mutation: flip bit. 17 B
006226 generated/0937 Generated true Seeded random text, mutation: flip bit. 14 B
006243 generated/0954 Generated true Seeded random text, mutation: flip bit. 5 B
006244 generated/0956 Generated true Seeded random text, mutation: flip bit. 150 B
006252 generated/0964 Generated true Seeded random text, mutation: flip bit. 194 B

Where these rules come from

Well-formed UTF-8 is defined by Table 3-7 of the Unicode Standard, chapter 3 , which RFC 3629 restates as ABNF. Every answer is agreed by simdutf 9.4.0, Python’s strict codec and a direct reading of the table; the suite’s own tests add Node.js’s buffer.isUtf8 and a fatal TextDecoder.