- How do I install test-discord-faker in a Laravel app?
- Install it as a Composer dev dependency using the package name mrgoodbytes8667/test-discord-faker. Keeping it in require-dev prevents test-only helpers from shipping to production. Then use its fakes and assertions inside your Laravel test suite.
- Does this package fake Discord webhooks or real Discord API calls?
- It fakes Discord webhook payloads and API responses so your tests do not hit Discord. The package includes realistic fixtures for messages, embeds, and interactions. It also provides assertions for outgoing requests, making webhook behavior deterministic in tests.
- Which Laravel and PHP versions are supported?
- The package is described as a Laravel/PHP testing helper, but exact Laravel and PHP constraints depend on its composer.json. Check the README or Packagist metadata before adopting it in a specific application. Confirm compatibility with your Laravel version and test runner.
- What Discord payloads can I fake with this package?
- The package provides realistic fixtures for Discord messages, embeds, and interactions. This lets you test webhook and API handling without calling Discord. You can assert that your application sends the expected outgoing request payloads.
- Can I use test-discord-faker outside Laravel?
- It is described as a Laravel/PHP testing helper, so it may work in plain PHP test suites depending on its dependencies. Laravel users get the most natural fit because it supports testing Discord webhooks and API responses. Verify the package requirements if you are not using Laravel.
- How do I assert that an outgoing Discord webhook request was sent?
- Use the package's assertions for outgoing requests after triggering the code that sends the webhook. The package is designed to inspect outgoing Discord requests and compare them against expected payloads. Check the README for the exact assertion method names and examples.
- Is test-discord-faker safe to use in production?
- No, it is a testing helper intended for deterministic tests, not production runtime behavior. Install it with Composer's require-dev flag and keep it out of production deployments. It is specifically useful for avoiding real Discord calls during test runs.
- How do I test Discord interactions such as slash commands?
- Use the package's realistic interaction fixtures to simulate Discord interaction payloads. Feed those fixtures into your handler and assert the resulting behavior or outgoing API responses. This lets you test interaction flows without contacting Discord.
- Does test-discord-faker make network requests to Discord?
- No, the package is designed to fake Discord webhook payloads and API responses so tests do not hit Discord. That keeps test results deterministic and avoids network flakiness or rate limits. It is intended for local and CI test environments.
- What are alternatives to test-discord-faker for Laravel Discord testing?
- You can use Laravel's HTTP fake helpers with custom Discord payload fixtures, but you would need to build the Discord-specific data and assertions yourself. This package adds realistic message, embed, and interaction fixtures plus outgoing request assertions. It is a focused alternative when you want Discord-aware testing helpers.