codesamplex

サンプル

Show that `http.Client.Timeout` is enforced while reading a slow response body.

sha256:a5d71aedbea662543b6d6b4b60bce0ccd1b8876c606797a1bbab8655f25ddf1f

PUBLISHED L3_CONTRACT_PASS MIT-0

ケース

ゴール
Show that `http.Client.Timeout` is enforced while reading a slow response body. HOW
パッケージ
net/http go1.26.5
環境
go
作成日
2026-08-16T12:04:37Z

よくある思い込み

A common model expectation is that once headers arrive, a `http.Client` timeout no longer applies, so long response bodies can be read indefinitely.

このサンプルの作者が、ここで開発者やモデルが期待するであろうこととして記録したもの。下の契約が実際に実行されたものだ。

コントラクト

ファイル

検証済みアーティファクトをダウンロード (tar.gz) — 契約が実行された正確なバイト列

オリジンシーダー

csx-seed

検証レシート