ruby

From RSpec to Minitest: first impressions
Sun, Jun 19, 2022 - ~600 Words
In testing Ruby/Rails systems I have used (and enjoyed) RSpec. In my current work RSpec is used but the principal testing framework is intended to be Minitest. Over the years I have heard it said many times that “Minitest is just Ruby” and so it has the advantage that everything you know about organising Ruby code can be applied to your tests, with no need to learn how a DSL such as RSpec approaches this problem.
Read more →
Initial Thoughts on Ruby Pattern Matching
Tue, Jul 2, 2019 - ~800 Words
This post represents a first attempt to evaluate the new pattern matching feature in Ruby 2.7 with a view to determining what use cases it might be a good fit for, both in general and in the context of Ruby. Thanks to @mametter for corrections to this post. Use case: processing JSON This is perhaps the most directly useful application of pattern matching that I could find. Taken from this slide.
Read more →
Improving Vim/Neovim Rendering Performance
Mon, Apr 15, 2019 - ~400 Words

A work in progress, but if you’re experiencing slow rendering performance in vim or neovim (particularly in Ruby files) then here is a list of things to try for a hopefully smoother experience.

Read more →
Recurring Issues Installing Ruby C Extensions on OSX Mojave
Thu, Mar 7, 2019 - ~400 Words

Recently I have had to take the time to fix failed installations of Ruby libraries which build C extensions on Mojave in multiple development environments and across multiple versions of Ruby. The solution(s) are in the end thankfully quite straightforward.

Read more →