Cucumber may complain about cucumber.yml being invalid when it is valid
Cucumber can report cucumber.yml as invalid even when it parses correctly; an invalid rerun file like tmp/rerun.txt may trigger the error.
RSpec: Increase readability with super_diff
Hard-to-read RSpec diffs for nested hashes and collections can be improved with super_diff, which formats expectation mismatches more clearly.
SSHKit 1.9.0 failure for Capistrano deploy
Capistrano deploys can crash in sshkit-1.9.0 with NoMethodError in pretty.rb; upgrading SSHKit to 1.21.0 resolves the failure.
Output of ParallelTests::Cucumber::FailuresLogger was fixed in 4.9.1
ParallelTests::Cucumber::FailuresLogger now emits valid rerun arguments in version 4.9.1, so patched custom loggers can be removed and the default logger restored.
BrowserStack has browser plugins for local testing
Private and internal servers can be tested through the BrowserStack cloud without exposing them publicly, even behind firewalls, proxies, or Active Directory.
How to fix: Bundler 1.13 breaks parallel_tests
Upgrading to Bundler 1.13.x can break parallel_tests with a LoadError when loading Gherkin formatters. Setting bundle config --local disable_exec_load true restores the old behavior.
Cucumber features as documentation
Natural-language Cucumber features and scenarios can capture intent and context beyond one-line labels, helping future developers understand application behavior quickly.
Fix a spec that only runs when called directly
RSpec examples that run only when invoked directly often need a proper _spec.rb filename; a plain .rb file may be skipped in the full suite.
Quick HTML testing with RubyMine
Quickly preview embed code or other HTML in RubyMine without creating a project file by using an HTML scratch file and opening it in a browser.
Heads up: RSpec's diffs may not tell the truth
RSpec diffs can mislead when matchers print like failures or when Time.now values differ only by milliseconds.
Understanding the Selenium error "Modal Dialog Present" (aka Selenium::WebDriver::Error::UnhandledAlertError)
Intermittent Cucumber failures can come from a leftover browser alert blocking Selenium commands after an unfinished AJAX request.
How to install packages from newer Ubuntu releases
Install newer Ubuntu release packages on an LTS system when new hardware or software needs them, while minimizing dependency conflicts and upgrade risk.
RCov: The difference between "code coverage" and "total coverage"
Code coverage can look misleading when blank lines and comments count against the ratio; RCov total coverage ignores them for a more useful metric.
Minify Font Awesome fonts with webpack
Reduce Font Awesome icon font size by subsetting unused glyphs with fontmin-webpack, keeping low CPU usage and no JavaScript while avoiding oversized font downloads.
Ruby object equality
Ruby equality methods differ by purpose: == for value comparison, eql? and hash for hash keys, === for case matching, equal? for identity.
How to: Validate dynamic attributes / JSON in ActiveRecord
JSONB columns can hold dynamic attributes in ActiveRecord, but validation and strict defaults are easy to lose. JSON Schema keeps evolving hashes predictable.
Show the character set and the collation of your MySQL tables
MySQL table collation and default character set are available through SHOW TABLE STATUS and SHOW CREATE TABLE; individual columns can still use different encodings.
GitHub Actions: Manually running a workflow
Manual workflow runs in GitHub Actions require workflow_dispatch; eligible workflows then appear in the Actions tab with a Run Workflow button.
Rails: How to write custom email interceptors
Global mail interception in Rails can prefix subjects by environment and redirect staging mail to a fallback address unless recipients are allowlisted.
Check that a Range covers an element in both Ruby 1.9 and 1.8.7
Range#include? becomes slow for non-numeric ranges in Ruby 1.9, while Range#cover? is unavailable in 1.8.7. A compatibility method keeps one check working across both versions.
Embed Google Analytics code for some environments only
Google Analytics should run only in production to avoid polluting visitor statistics. Rails environment checks can gate the tracking snippet.
Running Cucumber deletes my whole app!
Capybara Screenshot can delete the application directory during a Cucumber run when screenshots are stored in .. Upgrading to 1.0.26 and setting Capybara.save_path avoids the destructive cleanup.
Raise when there's a I18n translation missing
translate! and t! raise I18n::MissingTranslationData on missing translations instead of returning placeholder text. A custom exception handler can make I18n raise globally.
Performance analysis of MySQL's FULLTEXT indexes and LIKE queries for full text search
MySQL text search performance differs sharply between LIKE and FULLTEXT; LIKE stays surprisingly fast on medium datasets, while FULLTEXT benefits from larger vocabularies.