Improve RSpec tests