Using Low-Level Prompts for High-Accuracy AI Coding

Precise, low-level prompts and tight context improve AI code edits across files; structured keywords, reusable patterns, and early review reduce guesses and errors.

Howto: Create a self-signed certificate

Local HTTPS development often needs a trusted certificate; openssl or mkcert can create self-signed X.509 certificates for testing without browser warnings.

mattheworiordan/capybara-screenshot

Automatically saves failed Capybara test HTML and screenshots to tmp/capybara, helping diagnose flaky browser failures in Cucumber, RSpec, and Minitest.

mattheworiordan/capybara-screenshot

Captures browser screenshots on demand or automatically when tests fail, making visual debugging of Capybara runs easier.

Consider adding Reek to your CI pipeline

Reek detects Ruby code smells and antipatterns, helping assess merge request quality without blocking every warning. It fits CI as a non-blocking lint check.

yujinakayama/transpec: The RSpec syntax converter

Script to migrate test suites from RSpec 2 to RSpec 3, including syntax beyond should and expect.

colszowka/simplecov - GitHub

Ruby 1.9 code coverage tool with configurable reporting and automatic merging across test suites; rcov remains for Ruby 1.8.

Heads up: expect(object).to receive(:method_name) does not execute the original implementation of the method

receive(:method_name) stubs the original method implementation, so callbacks or side effects do not run during expectations. and_call_original preserves the real behavior.

Capistrano: exclude custom bundle groups for production deploy

Custom Bundler groups can still be downloaded during Capistrano deploys, slowing production and staging releases. Exclude unnecessary groups with bundle_without to avoid installing unused gems.

Error during Rails 5 upgrade: Environment data not found in the schema

Rails 5 upgrade can fail when the database schema lacks configured environment data, especially during parallel test database migration.

Wrapping Your API In A Custom Ruby Gem

Packaging API bindings as a custom Ruby gem makes reuse and distribution easier, with tests recording HTTP interactions through VCR.

Heartbleed test

Checks a server hostname for the Heartbleed vulnerability in OpenSSL (CVE-2014-0160).

How to add esbuild to the rails asset pipeline

Migrating a Rails app from Sprockets-only asset handling to esbuild adds modern JavaScript bundling and can surface path, font, and Sass compatibility issues.

Rspec: Expecting a Rake task to be called

Rake tasks can be verified in RSpec by expecting Rake::Task to receive invoke, useful for testing task-triggered side effects without putting logic in tasks.

Webservice to test and inspect requests

Temporary request URLs make it easy to inspect HTTP callbacks and webhooks; incoming traffic is recorded and displayed for debugging.

Error handling and reporting with Rails

Rails exception handling can either crash requests, hide actionable errors, or spam trackers; ExceptionApp, DebugExceptions, and the error reporter shape responses, logging, and notifications.

Rails: Reporting CSP Violations to a log file

Capture CSP violation reports in a log file to spot blocked resources and browser-extension noise, with a dedicated Rails endpoint for incoming reports.

Cucumber CI job quirks

Cucumber CI rerun logic can pass green after syntax errors when no failing_features file is written; native --retry avoids this edge case.

Beware: Coffeescript "in" is not the Javascript "in"

CoffeeScript in checks array membership, not object properties; JavaScript in tests whether an object has a property. Use of for property lookup in CoffeeScript.

Transactional HTML Email Templates

HTML email styling is fragile across clients and devices, making transactional messages hard to build and test. Open-source templates reduce the work needed for common transactional emails.

Maintaining custom application tasks in Rails

Large Rails projects benefit from keeping application tasks slim, separating the executable wrapper from the business code, and testing both rake tasks and scripts.

How to test inside iframes with cucumber / capybara

Cucumber and Capybara ignore iframes by default, so tests must switch into the frame to interact with its content. Frame-aware step definitions can reduce repeated setup.

Can I Email: Check what styling email clients support

Email client styling support is fragmented, so feature checks help avoid unsupported CSS but cannot replace real-client rendering tests.

JustinFrench.com: Learn how to test your code

Eventually you’ll forget that you used to spend hours testing your code in a browser, and start complaining that your automated tests are taking minutes to run! You’ll have intense debates with co-workers about what to test and how to test it properly. You’ll start writing the test first to expose the bug or missing feature, then write the code required to pass the test.