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

1,925 of 7,246 cases · 1,057 true · 868 false

Case Name Expected Note Size
005371 generated/0054 Generated false Seeded random text, mutation: replace byte. 328 B
005372 generated/0055 Generated true Seeded random text, mutation: none. 4 B
005373 generated/0056 Generated true Seeded random text, mutation: delete byte. 23 B
005374 generated/0057 Generated false Seeded random text, mutation: delete byte. 346 B
005375 generated/0058 Generated true Seeded random text, mutation: truncate. 31 B
005376 generated/0060 Generated true Seeded random text, mutation: flip bit. 195 B
005377 generated/0061 Generated false Seeded random text, mutation: replace byte. 135 B
005378 generated/0062 Generated true Seeded random text, mutation: none. 398 B
005379 generated/0063 Generated true Seeded random text, mutation: none. 244 B
005380 generated/0065 Generated true Seeded random text, mutation: none. 348 B
005381 generated/0066 Generated false Seeded random text, mutation: delete byte. 44 B
005382 generated/0067 Generated false Seeded random text, mutation: insert byte. 214 B
005383 generated/0068 Generated true Seeded random text, mutation: none. 53 B
005384 generated/0069 Generated true Seeded random text, mutation: none. 204 B
005385 generated/0070 Generated false Seeded random text, mutation: splice bad sequence. 22 B
005386 generated/0071 Generated true Seeded random text, mutation: none. 14 B
005387 generated/0072 Generated true Seeded random text, mutation: none. 76 B
005388 generated/0073 Generated false Seeded random text, mutation: replace byte. 32 B
005389 generated/0074 Generated false Seeded random text, mutation: insert byte. 30 B
005390 generated/0075 Generated false Seeded random text, mutation: splice bad sequence. 337 B
005391 generated/0076 Generated false Seeded random text, mutation: delete byte. 43 B
005392 generated/0077 Generated false Seeded random text, mutation: replace byte. 21 B
005393 generated/0078 Generated true Seeded random text, mutation: none. 68 B
005394 generated/0079 Generated true Seeded random text, mutation: none. 11 B
005395 generated/0080 Generated false Seeded random text, mutation: splice bad sequence. 19 B
005396 generated/0081 Generated true Seeded random text, mutation: flip bit. 5 B
005397 generated/0082 Generated false Seeded random text, mutation: delete byte. 22 B
005398 generated/0083 Generated true Seeded random text, mutation: truncate. 44 B
005399 generated/0084 Generated false Seeded random text, mutation: splice bad sequence. 13 B
005400 generated/0085 Generated false Seeded random text, mutation: flip bit. 201 B
005401 generated/0086 Generated false Seeded random text, mutation: replace byte. 88 B
005402 generated/0087 Generated true Seeded random text, mutation: none. 244 B
005403 generated/0088 Generated false Seeded random text, mutation: replace byte. 74 B
005404 generated/0089 Generated true Seeded random text, mutation: none. 63 B
005405 generated/0090 Generated true Seeded random text, mutation: none. 66 B
005406 generated/0091 Generated true Seeded random text, mutation: flip bit. 166 B
005407 generated/0092 Generated true Seeded random text, mutation: truncate. 5 B
005408 generated/0093 Generated true Seeded random text, mutation: none. 3 B
005409 generated/0094 Generated false Seeded random text, mutation: insert byte. 31 B
005410 generated/0095 Generated false Seeded random text, mutation: truncate. 2 B
005411 generated/0096 Generated false Seeded random text, mutation: splice bad sequence. 347 B
005412 generated/0097 Generated true Seeded random text, mutation: none. 377 B
005413 generated/0098 Generated true Seeded random text, mutation: none. 8 B
005414 generated/0099 Generated true Seeded random text, mutation: none. 272 B
005415 generated/0100 Generated true Seeded random text, mutation: none. 58 B
005416 generated/0101 Generated true Seeded random text, mutation: none. 58 B
005417 generated/0102 Generated false Seeded random text, mutation: flip bit. 44 B
005418 generated/0103 Generated true Seeded random text, mutation: none. 8 B
005419 generated/0104 Generated true Seeded random text, mutation: none. 6 B
005420 generated/0105 Generated true Seeded random text, mutation: replace byte. 3 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.