mock-server

75 deterministic fixtures for scraper e2e tests. MOCKSRV::index::OK

Every fixture serves a sentinel MOCKSRV::<name>::OK — scrape the URL, assert the sentinel. indirect means the sentinel is not in that response's own body; after JS means it only exists once scripts have run, so a plain fetch cannot match it.

Same list as JSON: /manifest.json

Meta

endpointwhat it doessentinel
/index page linking every fixtureMOCKSRV::index::OK
/healthliveness probeMOCKSRV::health::OK
/manifest.jsonthis catalogue, as JSON

Timing

endpointwhat it doessentinel
/timeout?timeout=20responds after N secondsMOCKSRV::timeout::OK
/drip?chunks=10&duration=5body trickles over N secondsMOCKSRV::drip::OK
/hangnever responds (5min cap)
/resetconnection dies mid-body

Status codes

endpointwhat it doessentinel
/flaky/reset?key=aclears one key, or all when omitted
/status/404any status codeMOCKSRV::status::OK indirect
/flaky?key=a&fail=2&code=503fails N times per key, then 200MOCKSRV::flaky::OK indirect

Redirects

endpointwhat it doessentinel
/redirect/3N-hop redirect chain
/redirect-to?url=/jsonsingle redirect to any URL
/redirect/loopinfinite redirect loop
/meta-refresh?to=/html/articlemeta-refresh redirect
/redirect/preserve-307307 — method and body preserved
/redirect/preserve-308308 — method and body preserved
/redirect/relativeLocation without a leading slash
/redirect/offsite?to=https://example.com/Location on another origin
/redirect/cookie-hopresolves only once the cookie is echoedMOCKSRV::redirect-cookie-hop::OK indirect

HTML shapes

endpointwhat it doessentinel
/html/iframe-childthe frame /html/iframe embedsMOCKSRV::html-iframe::OK
/html/articleclean article, og + ld+jsonMOCKSRV::html-article::OK
/html/malformedunclosed tagsMOCKSRV::html-malformed::OK
/html/huge?kb=500large payload, sentinel at endMOCKSRV::html-huge::OK
/html/charset?declare=headerISO-8859-9 bytesMOCKSRV::html-charset::OK indirect
/html/empty200 with empty body
/html/iframecontent in a child frameMOCKSRV::html-iframe::OK indirect
/html/noscriptcontent only in <noscript>MOCKSRV::html-noscript::OK
/html/boilerplatearticle buried in nav/aside/footer noiseMOCKSRV::html-boilerplate::OK
/html/richtables, code, lists, images — markdown fidelityMOCKSRV::html-rich::OK
/html/unicodeemoji, CJK, RTL, combining marks, BOMMOCKSRV::html-unicode::OK

JS / CSR

endpointwhat it doessentinel
/js/csr?delay=500CSR — JS writes content after N msMOCKSRV::js-csr::OK after JS
/js/fetchcontent via fetch() after loadMOCKSRV::json::OK indirect
/js/lazyIntersectionObserver, needs scrollMOCKSRV::js-lazy::OK after JS
/js/infinite?pages=3infinite scroll, N pagesMOCKSRV::js-infinite::OK after JS
/js/shadowcontent inside a shadow rootMOCKSRV::js-shadow::OK after JS
/js/redirect?to=/jsonlocation.replace navigation
/js/hydrateSSR markup replaced on hydrationMOCKSRV::js-hydrate::OK after JS

Walls + cookies

endpointwhat it doessentinel
/wall/cookieconsent overlay over contentMOCKSRV::wall-cookie::OK
/wall/cookie-gate403 unless cookie consent=1MOCKSRV::wall-cookie-gate::OK indirect
/cookies/set?name=consent&value=1sets a cookieMOCKSRV::cookies-set::OK
/wall/paywalltruncated article + paywallMOCKSRV::wall-paywall::OK
/wall/login401 login form
/wall/captcha403 captcha page
/wall/bot403 unless UA looks like a browserMOCKSRV::wall-bot::OK indirect

Auth

endpointwhat it doessentinel
/auth/basic?user=user&pass=passHTTP basic authMOCKSRV::auth-basic::OK indirect
/auth/bearer?token=secretbearer token authMOCKSRV::auth-bearer::OK indirect

Content types

endpointwhat it doessentinel
/jsonapplication/jsonMOCKSRV::json::OK
/xmlapplication/xmlMOCKSRV::xml::OK
/csvtext/csvMOCKSRV::csv::OK
/texttext/plainMOCKSRV::text::OK
/pdfapplication/pdfMOCKSRV::pdf::OK
/gzipgzip-encoded htmlMOCKSRV::gzip::OK indirect
/content-type?type=application/octet-streamhtml served as any typeMOCKSRV::content-type::OK
/bytes/1024exact N bytes
/brotlibrotli-encoded htmlMOCKSRV::brotli::OK indirect
/deflatedeflate-encoded htmlMOCKSRV::deflate::OK indirect

Lying headers

endpointwhat it doessentinel
/lie/gzipdeclares gzip, sends plain textMOCKSRV::lie-gzip::OK indirect
/lie/charsetdeclares utf-8, sends latin5MOCKSRV::lie-charset::OK indirect
/lie/lengthcontent-length >> body, then socket dropMOCKSRV::lie-length::OK indirect

Caching + rate limits

endpointwhat it doessentinel
/cache/etagETag, 304 on If-None-MatchMOCKSRV::cache-etag::OK
/cache/last-modifiedLast-Modified, 304 on If-Modified-SinceMOCKSRV::cache-last-modified::OK
/rate-limit429 + retry-after seconds + x-ratelimit-*
/rate-limit/date503 + retry-after as an HTTP-date

Crawl surface

endpointwhat it doessentinel
/robots.txtdisallows /blocked/
/sitemap.xml?n=10N urls
/blocked/pagerobots-disallowed pageMOCKSRV::blocked::OK
/links?n=20page with N internal linksMOCKSRV::links::OK
/deep/1each level links to the nextMOCKSRV::deep-1::OK
/crawl/page/1leaf page, sitemap targetMOCKSRV::crawl-page::OK
/html/base-href<base href> rewrites relative linksMOCKSRV::html-base-href::OK
/html/norobotsmeta robots noindex,nofollow + rel=nofollowMOCKSRV::html-norobots::OK
/html/canonicalnear-duplicate, canonical to /html/articleMOCKSRV::html-canonical::OK
/html/paginated?page=1rel=next / rel=prev paginationMOCKSRV::html-paginated::OK

Diagnostics

endpointwhat it doessentinel
/headersechoes request headersMOCKSRV::headers::OK
/echoechoes method, headers, bodyMOCKSRV::echo::OK