Click on a piece of text in Cucumber / Capyabra
Clicking arbitrary page text can target any HTML element with a JavaScript handler, not just links or buttons, in Selenium features.
Speed up large Cucumber test suites
Large Cucumber suites can become slow as they grow; deferring garbage collection during scenarios can noticeably reduce overall execution time.
New cards feature: Personal RSS feed that includes public and private cards
Account profiles now provide a personal RSS feed with the newest public and private cards across all decks.
New cards feature: Explicit language declaration for syntax highlighting
Short code snippets can be misclassified by automatic syntax highlighting; explicitly declaring the language or using text avoids wrong highlighting or disables it.
Bundler: Fatal error and 'no such file to load -- net/https'
Bundler can fail on fresh Ubuntu installs with no such file to load -- net/https when Ruby lacks OpenSSL bindings, blocking gem downloads.
When overriding #method_missing, remember to override #respond_to_missing? as well
Dynamic Ruby methods can return false negatives with respond_to?, breaking gems and method lookups unless respond_to_missing? matches method_missing.
How to: Limit or disable textarea resizing in Chrome and Firefox
Textarea resizing in Chrome, Safari, and Firefox can disrupt layouts; limiting maximum width and height keeps the box controlled while still allowing optional user resizing.
Cucumber: Calling multiple steps from a step definition
Reusable Gherkin steps can be chained inside a new step definition with steps or step, but steps only processes lines starting with Gherkin keywords.
Install rabbitmq plugins (e.g. management plugin) on Ubuntu 12.04
RabbitMQ plugins on Ubuntu 12.04 require the full rabbitmq-plugins path because the binary is not in the default PATH.
Run specific version of bundler
Run an older Bundler release for compatibility when Rails or another project is pinned to a specific gem version.
Rails 3.1 gives you free down migrations
Rails 3.1 lets a single change migration run forward and backward automatically, while irreversible updates are skipped during rollback.
Setup your terminal to not scroll when there is new output
Stop the terminal from jumping back to the bottom when new output appears, so you can inspect logs or test failures without losing your place.
Ruby 1.8.7-p370 released
Final bugfix release for Ruby 1.8.7, with another year of security fixes before patches end.
Updated: Test a gem in multiple versions of Rails
Testing a gem across Rails versions is easier with shared app code and specs via symlinks, keeping one test setup aligned with current best practice.
has_defaults is now a gem
has_defaults is now a standalone gem; the old plugin is gone and plugins are unsupported in Rails 3.2+.
Err http://de.archive.ubuntu.com [...] 404 Not Found [IP: 141.30.13.20 80]
APT fails with 404 errors from an Ubuntu mirror while the network and server are fine; deleting the local package lists cache restores updates.
Consul 0.3.0 has a shortcut to quickly create an action map for CRUD controllers
Moderately complex authorization rules often need CRUD action mapping in controllers; Consul 0.3.0 adds :crud as a shortcut for the common edit/create/destroy mapping.
rake spec + rails_admin = weirdly failing specs
rails_admin specs can pass with rspec but fail under rake spec; setting ENV['SKIP_RAILS_ADMIN_INITIALIZER'] = 'false' in spec_helper restores the initializer.
How to deal with: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type [...] at
Puppet catalog compilation can fail with ArgumentError: Invalid resource type when plugin sync or environments are misconfigured. Missing Ruby files in /var/lib/puppet/lib can trigger the error.
Get the initial username which you used to login to your Linux system
Find the currently logged-in Linux user with whoami; use it in .bashrc to set different Bash prompts for root and normal users.
Difference between class_inheritable_attribute and class_attribute | martinciu's dev blog
class_attribute behavior in Rails can differ from the removed class_inheritable_attribute, especially when inheritable class state is needed across subclasses.
Rack dies when parsing large forms
Rack can reject large nested forms by miscounting input fields against its parameter limit, causing low-level Ruby errors or Rails error pages.
RSpec claims nil to be false
RSpec be_false matches nil, so a false check can pass unexpectedly. Use == false when the value must be exactly false.
Deal with error: Expected foo_trait.rb to define FooTrait
Rails autoloading can surface a misleading Expected foo_trait.rb to define FooTrait error after a mistake in an unrelated trait, making the real failure hard to locate.