Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Phpunit Json Assertions

Phpunit Json Assertions Laravel Package

estahn/phpunit-json-assertions

Expressive JSON assertions for PHPUnit. Verify API responses and JSON documents by structure, values, and types without manually decoding payloads or hand-checking nested arrays. Works with existing test cases to keep your suite readable, precise, and concise.

Deep Wiki
Context7

estahn/phpunit-json-assertions adds expressive JSON assertions to PHPUnit, so you can verify API responses and payloads without decoding them by hand. Compare raw JSON strings against PHP arrays, fixture files, or expected subsets—and get clear, readable diffs when a structure doesn't match.

  • assertJsonMatchesArray() / assertJsonMatchesFile() for exact structural comparisons
  • Subset matching with assertJsonContains() and its negation
  • Key and value validation against expected JSON
  • Readable failure output highlighting the mismatch
  • Install via composer require --dev estahn/phpunit-json-assertions
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource