Skip to content

Instantly share code, notes, and snippets.

View devoracer's full-sized avatar

Chris Peterson devoracer

View GitHub Profile
@devoracer
devoracer / bikehashes.rb
Last active April 10, 2016 19:54
Only the bike section of the hashes sheet
def test_array_of_hashes
rides = [
{
:location => "Denver",
:distance => 40,
:avg_speed => 18,
:type => :road
},
{
location: "Golden",
@devoracer
devoracer / hashes.rb
Last active April 5, 2016 02:33
tests
require File.expand_path(File.dirname(__FILE__) + '/neo')
class AboutHashes < Neo::Koan
def test_creating_hashes
empty_hash = Hash.new
assert_equal Hash, empty_hash.class
assert_equal({}, empty_hash)
assert_equal 0, empty_hash.size
end