Sha256: d6bb1de521617d70579994605ebf803819d33bdc5900ad603cc92f441d519980
Contents?: true
Size: 477 Bytes
Versions: 5
Compression:
Stored size: 477 Bytes
Contents
require 'spec' $:.unshift(File.dirname(__FILE__) + '/../../lib') require 'calculator' Before do @calc = Calculator.new end After do end Given "I have entered $n into the calculator" do |n| @calc.push n.to_i end When /I press (\w+)/ do |op| @result = @calc.send op end Then /the result should be (.*) on the screen/ do |result| @result.should == result.to_f end Then /the result class should be (\w*)/ do |class_name| @result.class.name.should == class_name end
Version data entries
5 entries across 5 versions & 3 rubygems