SIGN IN SIGN UP

KTOR-9784 Support multipart on non-JVM server targets (#5804)

* KTOR-9784 Support multipart on non-JVM server targets

The default receive transformation delegated multipart handling to a
platform-specific `multiPartData`, and the non-JVM actual threw. As a result,
on Native and JS/Wasm `receiveMultipart()` failed with
CannotTransformContentToTypeException, and `receiveParameters()` with a
multipart body threw IllegalStateException.

The CIO multipart parser was moved to commonMain in KTOR-6632 so that the
client could parse multipart responses on every target, but the server was
never re-wired. Move the JVM `multiPartData` implementation to commonMain and
handle `MultiPartData` in the common transformation. No new dependency is
required and no public API changes.

* KTOR-9784 Release the form item and assert status in multipart tests

Release the part right after reading its name and value, matching the
convention used by the other tests in this file, and assert the response
status before the body so that a failed request reports the status rather
than a mismatched error page.
S
sangyong committed
9f7f589cbb57a59b16f82f077bdc3d906a202ce9
Parent: ad394e4
Committed by GitHub <noreply@github.com> on 8/19/2026, 1:17:30 PM