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

All 7,246 cases · 2,791 true · 4,455 false

Case Name Expected Note Size
005550 generated/0236 Generated true Seeded random text, mutation: none. 3 B
005551 generated/0237 Generated false Seeded random text, mutation: splice bad sequence. 338 B
005552 generated/0238 Generated false Seeded random text, mutation: replace byte. 301 B
005553 generated/0239 Generated true Seeded random text, mutation: none. 6 B
005554 generated/0240 Generated true Seeded random text, mutation: replace byte. 258 B
005555 generated/0241 Generated true Seeded random text, mutation: none. 28 B
005556 generated/0242 Generated true Seeded random text, mutation: none. 28 B
005557 generated/0243 Generated false Seeded random text, mutation: truncate. 10 B
005558 generated/0244 Generated false Seeded random text, mutation: flip bit. 11 B
005559 generated/0245 Generated false Seeded random text, mutation: splice bad sequence. 10 B
005560 generated/0246 Generated true Seeded random text, mutation: none. 12 B
005561 generated/0247 Generated false Seeded random text, mutation: splice bad sequence. 16 B
005562 generated/0248 Generated false Seeded random text, mutation: delete byte. 53 B
005563 generated/0249 Generated true Seeded random text, mutation: none. 6 B
005564 generated/0250 Generated true Seeded random text, mutation: none. 247 B
005565 generated/0251 Generated true Seeded random text, mutation: none. 5 B
005566 generated/0252 Generated false Seeded random text, mutation: delete byte. 79 B
005567 generated/0253 Generated true Seeded random text, mutation: none. 116 B
005568 generated/0254 Generated false Seeded random text, mutation: delete byte. 29 B
005569 generated/0255 Generated true Seeded random text, mutation: none. 4 B
005570 generated/0256 Generated false Seeded random text, mutation: insert byte. 14 B
005571 generated/0257 Generated true Seeded random text, mutation: none. 12 B
005572 generated/0258 Generated true Seeded random text, mutation: none. 114 B
005573 generated/0259 Generated false Seeded random text, mutation: truncate. 2 B
005574 generated/0260 Generated true Seeded random text, mutation: truncate. 278 B
005575 generated/0261 Generated false Seeded random text, mutation: replace byte. 23 B
005576 generated/0262 Generated false Seeded random text, mutation: insert byte. 393 B
005577 generated/0263 Generated true Seeded random text, mutation: none. 20 B
005578 generated/0265 Generated false Seeded random text, mutation: truncate. 11 B
005579 generated/0266 Generated true Seeded random text, mutation: none. 15 B
005580 generated/0267 Generated true Seeded random text, mutation: none. 346 B
005581 generated/0268 Generated true Seeded random text, mutation: none. 30 B
005582 generated/0269 Generated false Seeded random text, mutation: splice bad sequence. 17 B
005583 generated/0270 Generated true Seeded random text, mutation: none. 36 B
005584 generated/0271 Generated false Seeded random text, mutation: insert byte. 75 B
005585 generated/0272 Generated true Seeded random text, mutation: flip bit. 10 B
005586 generated/0273 Generated false Seeded random text, mutation: insert byte. 70 B
005587 generated/0274 Generated false Seeded random text, mutation: delete byte. 9 B
005588 generated/0275 Generated true Seeded random text, mutation: none. 389 B
005589 generated/0276 Generated false Seeded random text, mutation: replace byte. 24 B
005590 generated/0277 Generated true Seeded random text, mutation: none. 62 B
005591 generated/0278 Generated false Seeded random text, mutation: delete byte. 380 B
005592 generated/0279 Generated false Seeded random text, mutation: truncate. 6 B
005593 generated/0280 Generated true Seeded random text, mutation: none. 26 B
005594 generated/0281 Generated false Seeded random text, mutation: splice bad sequence. 337 B
005595 generated/0282 Generated true Seeded random text, mutation: flip bit. 6 B
005596 generated/0283 Generated true Seeded random text, mutation: none. 46 B
005597 generated/0284 Generated false Seeded random text, mutation: truncate. 19 B
005598 generated/0286 Generated false Seeded random text, mutation: insert byte. 147 B
005599 generated/0287 Generated true Seeded random text, mutation: replace byte. 8 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.