Resource files can declare a non-default character encoding
All 3 scenarios hold
A table can live in a classpath resource file instead of the annotation: @TableTest(resource = "external.table", encoding = "UTF-8").
The first three rules below call the loading API with those same arguments. Their tables can therefore show which paths resolve, what text the file's bytes become, and how loading fails.
The rules after them are driven by the very files shown. Each row comes from a line of the file rather than from the annotation.
The rows below are the lines of src/test/resources/subfolder/custom_encoding.table. The rule reads that file with encoding = "ISO-8859-1". The letters in the last row count as six characters. That holds only where the rule reads the file in the encoding the author wrote it in.
expected outcome
broken scenario
| string | length? |
|---|---|
| “” | 0 |
| abc | 3 |
| ÉÜ¥ÆØÅ | 6 |