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
005324 generated/0003 Generated false Seeded random text, mutation: flip bit. 4 B
005327 generated/0007 Generated true Seeded random text, mutation: flip bit. 388 B
005350 generated/0031 Generated false Seeded random text, mutation: flip bit. 276 B
005376 generated/0060 Generated true Seeded random text, mutation: flip bit. 195 B
005396 generated/0081 Generated true Seeded random text, mutation: flip bit. 5 B
005400 generated/0085 Generated false Seeded random text, mutation: flip bit. 201 B
005406 generated/0091 Generated true Seeded random text, mutation: flip bit. 166 B
005417 generated/0102 Generated false Seeded random text, mutation: flip bit. 44 B
005429 generated/0114 Generated true Seeded random text, mutation: flip bit. 66 B
005434 generated/0120 Generated false Seeded random text, mutation: flip bit. 4 B
005441 generated/0127 Generated true Seeded random text, mutation: flip bit. 8 B
005447 generated/0133 Generated true Seeded random text, mutation: flip bit. 87 B
005469 generated/0155 Generated true Seeded random text, mutation: flip bit. 10 B
005471 generated/0157 Generated true Seeded random text, mutation: flip bit. 8 B
005481 generated/0167 Generated false Seeded random text, mutation: flip bit. 8 B
005496 generated/0182 Generated false Seeded random text, mutation: flip bit. 7 B
005497 generated/0183 Generated true Seeded random text, mutation: flip bit. 15 B
005498 generated/0184 Generated true Seeded random text, mutation: flip bit. 27 B
005502 generated/0188 Generated false Seeded random text, mutation: flip bit. 6 B
005506 generated/0192 Generated true Seeded random text, mutation: flip bit. 16 B
005526 generated/0212 Generated true Seeded random text, mutation: flip bit. 149 B
005541 generated/0227 Generated true Seeded random text, mutation: flip bit. 62 B
005549 generated/0235 Generated false Seeded random text, mutation: flip bit. 312 B
005558 generated/0244 Generated false Seeded random text, mutation: flip bit. 11 B
005585 generated/0272 Generated true Seeded random text, mutation: flip bit. 10 B
005595 generated/0282 Generated true Seeded random text, mutation: flip bit. 6 B
005604 generated/0292 Generated true Seeded random text, mutation: flip bit. 74 B
005619 generated/0307 Generated false Seeded random text, mutation: flip bit. 33 B
005625 generated/0313 Generated false Seeded random text, mutation: flip bit. 12 B
005637 generated/0325 Generated true Seeded random text, mutation: flip bit. 52 B
005643 generated/0331 Generated true Seeded random text, mutation: flip bit. 11 B
005668 generated/0356 Generated false Seeded random text, mutation: flip bit. 304 B
005673 generated/0361 Generated true Seeded random text, mutation: flip bit. 287 B
005694 generated/0382 Generated true Seeded random text, mutation: flip bit. 11 B
005701 generated/0389 Generated true Seeded random text, mutation: flip bit. 9 B
005712 generated/0400 Generated true Seeded random text, mutation: flip bit. 39 B
005715 generated/0403 Generated true Seeded random text, mutation: flip bit. 26 B
005716 generated/0404 Generated false Seeded random text, mutation: flip bit. 37 B
005719 generated/0407 Generated true Seeded random text, mutation: flip bit. 361 B
005720 generated/0408 Generated true Seeded random text, mutation: flip bit. 4 B
005726 generated/0414 Generated true Seeded random text, mutation: flip bit. 309 B
005732 generated/0420 Generated true Seeded random text, mutation: flip bit. 4 B
005740 generated/0428 Generated true Seeded random text, mutation: flip bit. 12 B
005752 generated/0441 Generated true Seeded random text, mutation: flip bit. 5 B
005797 generated/0489 Generated true Seeded random text, mutation: flip bit. 333 B
005799 generated/0491 Generated true Seeded random text, mutation: flip bit. 4 B
005805 generated/0497 Generated true Seeded random text, mutation: flip bit. 4 B
005817 generated/0509 Generated true Seeded random text, mutation: flip bit. 75 B
005832 generated/0524 Generated true Seeded random text, mutation: flip bit. 105 B
005843 generated/0538 Generated true Seeded random text, mutation: flip bit. 15 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.