Project Ramon

A learning journey from a Ruby noob perspective

Rails Multi-tenant update && Capybara Functional Coverage


Hello and happy Wednesday!

I have been spending most of my free time lately attempting to implement multi-tenancy in my Rails application. I’ve had to start over a few times for the various strategies I’ve seen online thus far. During this latest restart I had the mind to add functional tests with Capybara to help me isolate where my application breaks if I run into the same sort of issues in future attempts.

I’ll create another post when I finish my project’s functional tests, just to illustrate, but if you’re wanting a better introduction to Capybara testing you can check out this post I wrote back in march for a decent primer on the topic.

Capybara Troubleshooting: Not Finding Form Elements

This find was capybara troubleshooting gold for me.

I remember my first time writing integration tests for an internship, and wrestling at times with capybara being able to locate form fields properly. When I ran into a similar challenge this week, I was able to find this StackOverflow on the issue, and the top answer fixed my issue:



And lastly, I wanted to share a couple of capybara resources I’ve found helpful while building out these tests:

Stay tuned…


Categories: Ruby on rails

Tags: , ,

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s