php-xapi/json-test-fixtures
A collection of JSON test fixtures for the php-xapi ecosystem, offering ready-made xAPI statement samples and related JSON documents to simplify writing and running unit tests in your PHP projects.
metadata (the JSON-encoded attachment) and optional content (raw attachment bytes). Any suite that consumed the old flat value must be migrated. This is a bounded, mechanical migration and should be scoped as a scheduled maintenance task, not treated as a re-architecture.content is now optional, teams can express metadata-only attachments (filename, mime type, size, headers) without generating or loading a payload. Attachment test cases become cheap to add, which raises coverage per engineering hour.Adopt when:
Look elsewhere when:
Migration checklist for teams already on the prior major: inventory every fixture construction site, convert each to { metadata, content? }, decide per fixture whether raw content is genuinely asserted on, then re-run suites. Expect failures wherever tests assumed a flat encoded value.
Executives: this is a small, low-risk test-infrastructure dependency, and v2.0.0 is a breaking change with a bounded, mechanical migration. Cost is a few engineer-days of fixture updates; the offset is cheaper attachment coverage, since raw content is now optional and we stop paying to materialize bytes we never assert on. No customer-facing impact and no architecture change. The only real decision is timing — fold the upgrade into the next maintenance window rather than letting it become an ad-hoc scramble later.
Engineering: v2 changes the fixture contract. Each attachment fixture is now an object with up to two keys — metadata (JSON-encoded attachment) and, when present, content (raw attachment content). Anything consuming the old shape must be updated. The tradeoff is worth taking: metadata and bytes are now separable, so metadata-only fixtures are cheap and large binaries are opt-in. Recommendation is to pin the major, do the conversion as one mechanical commit per repo, and record the convention so new tests are written against the v2 shape from day one.
How can I help you explore Laravel packages today?