Topic: How would you rspec test nested controllers
Can anyone point me to examples of testing nested controllers please?
I'm new to rspec so not finding the syntax easy!
- Client and Trip models are related through TripClients (has many through).
- Trips are nested within Clients in the urls, eg: /clients/1/trips/new.
- Additionally, each Trip has many TripElement objects.
I found these articles but could not quite follow them enough to adapt to my scenario: