Skip to content

Instantly share code, notes, and snippets.

@olivierlacan
Created December 16, 2013 22:18
Show Gist options
  • Select an option

  • Save olivierlacan/7995477 to your computer and use it in GitHub Desktop.

Select an option

Save olivierlacan/7995477 to your computer and use it in GitHub Desktop.
Cool way to shell out in order to test that an external dependency (gem) can be require successfully, courtesy of Tyler Hunt.
describe 'Ransack' do
it 'can be required without errors' do
output = `bundle exec ruby -e "require 'ransack'" 2>&1`
output.should be_empty
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment