inertiajs / inertia-rails

The Rails adapter for Inertia.js.
https://inertia-rails.dev/
MIT License
574 stars 45 forks source link

Better setup specs warning #62

Closed bknoles closed 3 years ago

bknoles commented 3 years ago

Resolves #61

As noted by @christoomey , the error message for ensuring users set inertia: true in RSpec specs can be misleading.

This PR changes the code to check the actual example metadata before warning about the test setup.

Additionally, it adds a warning when you create a spec that expects inertia but never creates an inertia renderer. This isn't directly part of #61, but is something that has tripped me up in the past.

christoomey commented 3 years ago

Looks good to me! Thanks for the quick update 🚀