Preface: Normally, you would not need this in integrations tests (probably that's why it is so hard to achieve...
The translation method translate and its alias t have bang brothers: translate! and t!. They will raise I18n::MissingTranslationData on...
CSS3 comes with new unit rem. It works like em but it is always relative to the element instead of...
I had some problems with Git and the file spec/fixtures/ČeskýÁČĎÉĚÍŇÓŘŠŤÚŮÝŽáčďéěíňóřšťúůýž. After pulling the latest commits, it would show that...
When two classes implement the same behavior (methods, callbacks, etc.), you should extract that behavior into a trait or module...
Custom matchers are a useful RSpec feature which you can use to DRY up repetitive expectations in your specs. Unfortunately...
Shared example groups are a useful RSpec feature. Unfortunately the default directory structure generated by rspec-rails has no obvious...
Simply give the select helper an option :disabled, passing either a single value or an array. You need to specify...
For Capybara, use this step: Then /^"([^"]*)" should be a disabled option for "([^"]*)"(?: within "([^\"]*)")?$/ do |value, field, selector| with_scope(selector...
So you're hunting down a regression (or just a bug) and want to use git bisect to find out...
Consul 0.9 comes with many new features to optimize powers that only check access to a given record. e.g. Power.current.post...
I recently encountered the error above when I was running selenium tests. Thanks to a post on stackoverflow I found...
Similar to closing an opened browser window, spreewald now supports the I switch to the new browser tab step.
1. Saving files to a directory that is not shared between deploys or servers If you save your uploads to...
This card shows how to upgrade a Rails 2 application from Rails 2.3.8 through every single patch level up to...
Merge requests are often rejected for similar reasons. To avoid this, before you send a merge request, please confirm that...
Capybara drivers will usually delete all cookies after each scenario. If you need to lose cookie data in the middle...
When you need to find out in which kind of spec you are during run-time, it's definitely possible...
Sometimes you need a piece of code to do something different for specs than for features. If you don't...
When your site is on HTTPS and you are linking or redirecting to a HTTP site, the browser will not...
We have often felt the pain where our models need to serve too many masters. E.g. we are adding a...
In the following example the method update_offices_people_count won't be called when office_id changes, because it...
We ran into trouble when adding additional compute units to our railscomplete Hosting environment lately. VM-instances on the new...
Rails gives you migrations to change your database schema with simple commands like add_column or update. Unfortunately these commands...