Skip to content

Instantly share code, notes, and snippets.

TEST_ARRAY = [
["Number", "Name", "Position", "Points per Game"],
["12","Joe Schmo","Center",[14, 32, 7, 0, 23] ],
["9", "Ms. Buckets ", "Point Guard ", [19, 0, 11, 22, 0] ],
["31", "Harvey Kay", "Shooting Guard", [0, 30, 16, 0, 25] ],
["18", "Sally Talls", "Power Forward ", [18, 29, 26, 31, 19] ],
["22", "MK DiBoux ", "Small Forward ", [11, 0, 23, 17, 0] ]
]
# Expected first element after transform to hash
TEST_ARRAY = [
["Number", "Name", "Position", "Points per Game"],
["12","Joe Schmo","Center",[14, 32, 7, 0, 23] ],
["9", "Ms. Buckets ", "Point Guard ", [19, 0, 11, 22, 0] ],
["31", "Harvey Kay", "Shooting Guard", [0, 30, 16, 0, 25] ],
["18", "Sally Talls", "Power Forward ", [18, 29, 26, 31, 19] ],
["22", "MK DiBoux ", "Small Forward ", [11, 0, 23, 17, 0] ]
]
require_relative 'vehicle'
require 'rspec'
describe Car do
before :each do
@the_car = Car.new({color: 'black'})
end
it "should drive" do
require './vehicle'
my_car = Car.new(:color => "blue")
my_car.needs_gas?
my_car.drive
my_car.brake
my_bus = Bus.new(:color => "yellow")
my_bus.drive
my_bus.brake