Skip to content

Instantly share code, notes, and snippets.

View ennukee's full-sized avatar
🍀
always chilling

Dylan Bowers ennukee

🍀
always chilling
View GitHub Profile
import sys, csv, time, re
import datetime
from collections import defaultdict
class Employee:
def __init__(self, name, times):
self.name = name
self.times = times
def is_available_at(self, when):
@ennukee
ennukee / shared_examples.md
Last active October 10, 2025 14:49
An article on the usage of RSpec Shared Examples by Dylan Bowers

Disclaimers and information

Written on April 25th, 2016. Last updated on April 25th, 2016.

Disclaimer: Keep in mind the code in this article may become outdated as time progresses. Please use at your own discretion and make sure you are updated on any major syntactical changes before utilizing the code structures used below.

This article assumes you have intermediate knowledge of Ruby and RSpec. A large portion of this article also uses concepts in Ruby on Rails. Most of the article will be given in code, so make sure you are comfortable in reading others' code as well.

The "hidden" power of shared examples

By Dylan Bowers