{
  "columns": [
    "Sample",
    "Test",
    "Result",
    "Unit",
    "Method"
  ],
  "cases": [
    {
      "id": "aligned-two-page",
      "file": "aligned-two-page.pdf",
      "document_class": "aligned_native_table",
      "expected_rows": [
        {
          "page": 0,
          "fields": {
            "Sample": {
              "raw": "MAT-010",
              "value": "MAT-010",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Strength",
              "value": "Strength",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "52.70",
              "value": "52.70",
              "state": "extracted",
              "comparator": null
            },
            "Unit": {
              "raw": "MPa",
              "value": "MPa",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-A",
              "value": "TEST-A",
              "state": "extracted",
              "comparator": null
            }
          }
        },
        {
          "page": 0,
          "fields": {
            "Sample": {
              "raw": "MAT-011",
              "value": "MAT-011",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Moisture",
              "value": "Moisture",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "< 0.0050",
              "value": "0.0050",
              "state": "extracted",
              "comparator": "<"
            },
            "Unit": {
              "raw": "%",
              "value": "%",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-B",
              "value": "TEST-B",
              "state": "extracted",
              "comparator": null
            }
          }
        },
        {
          "page": 0,
          "fields": {
            "Sample": {
              "raw": "00087",
              "value": "00087",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Residue",
              "value": "Residue",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "0",
              "value": "0",
              "state": "extracted",
              "comparator": null
            },
            "Unit": {
              "raw": "mg",
              "value": "mg",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-C",
              "value": "TEST-C",
              "state": "extracted",
              "comparator": null
            }
          }
        },
        {
          "page": 1,
          "fields": {
            "Sample": {
              "raw": "MAT-012",
              "value": "MAT-012",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Density",
              "value": "Density",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "1,450",
              "value": null,
              "state": "unsupported",
              "comparator": null
            },
            "Unit": {
              "raw": "g/cm3",
              "value": "g/cm3",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-D",
              "value": "TEST-D",
              "state": "extracted",
              "comparator": null
            }
          }
        },
        {
          "page": 1,
          "fields": {
            "Sample": {
              "raw": "MAT-013",
              "value": "MAT-013",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Strength",
              "value": "Strength",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "",
              "value": null,
              "state": "not_reported",
              "comparator": null
            },
            "Unit": {
              "raw": "MPa",
              "value": "MPa",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-E",
              "value": "TEST-E",
              "state": "extracted",
              "comparator": null
            }
          }
        },
        {
          "page": 1,
          "fields": {
            "Sample": {
              "raw": "MAT-014",
              "value": "MAT-014",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Change",
              "value": "Change",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "-2.30",
              "value": "-2.30",
              "state": "extracted",
              "comparator": null
            },
            "Unit": {
              "raw": "%",
              "value": "%",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-F",
              "value": "TEST-F",
              "state": "extracted",
              "comparator": null
            }
          }
        }
      ],
      "expected_pages": 2,
      "required_exceptions": [
        "unsupported",
        "notreported"
      ],
      "expected_rejected": false,
      "limitation": "One layout, six synthetic rows, two pages with repeated exact headers; not representative of natural supplier reports."
    },
    {
      "id": "wrapped-cell",
      "file": "wrapped-cell.pdf",
      "document_class": "unsupported_wrapped_cell",
      "expected_rows": [
        {
          "page": 0,
          "fields": {
            "Sample": {
              "raw": "MAT-020",
              "value": "MAT-020",
              "state": "extracted",
              "comparator": null
            },
            "Test": {
              "raw": "Thermal expansion",
              "value": "Thermal expansion",
              "state": "extracted",
              "comparator": null
            },
            "Result": {
              "raw": "11.20",
              "value": "11.20",
              "state": "extracted",
              "comparator": null
            },
            "Unit": {
              "raw": "ppm/K",
              "value": "ppm/K",
              "state": "extracted",
              "comparator": null
            },
            "Method": {
              "raw": "TEST-G",
              "value": "TEST-G",
              "state": "extracted",
              "comparator": null
            }
          }
        }
      ],
      "expected_pages": 1,
      "required_exceptions": [
        "unmapped_line"
      ],
      "expected_rejected": false,
      "limitation": "Expected semantic cell is Thermal expansion. Parser retains Thermal and flags the continuation; report the incomplete field as a failure."
    },
    {
      "id": "different-headers",
      "file": "different-headers.pdf",
      "document_class": "unsupported_header_mismatch",
      "expected_rows": [],
      "expected_pages": 1,
      "required_exceptions": [
        "unsupported_layout"
      ],
      "expected_rejected": false,
      "limitation": "Property does not match the Test schema header. No rows expected under the fixed CLI schema; this is an unsupported-state check, not successful extraction."
    },
    {
      "id": "textless",
      "file": "textless.pdf",
      "document_class": "textless_synthetic_page",
      "expected_rows": [],
      "expected_pages": 1,
      "required_exceptions": [
        "ocr_no_text"
      ],
      "expected_rejected": false,
      "limitation": "Drawn shapes without a text layer exercise OCR fallback and its no-readable-text outcome; this is not a recognition-quality test or a natural scanned document."
    },
    {
      "id": "malformed",
      "file": "malformed.pdf",
      "document_class": "invalid_pdf",
      "expected_rows": [],
      "expected_pages": 0,
      "required_exceptions": [],
      "expected_rejected": true,
      "limitation": "An intentionally invalid PDF must fail preflight."
    }
  ]
}
