Last active
August 29, 2015 14:02
-
-
Save sonianand11/8120a690ad493f5b999b to your computer and use it in GitHub Desktop.
This is for testing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Foo | |
def initialize(thing) | |
@thing = thing | |
end | |
def test_me | |
if @thing.big? | |
'Big!' | |
else | |
'Small!' | |
end | |
end | |
end | |
require "test/unit" | |
class TestFoo < Test::Unit::TestCase | |
def test_simple | |
assert_equal('Big!', Foo.new('Big!').test_me ) | |
end | |
end |
module Foo
def blah;puts 'helo';end
end
class Bar
end
# how do I do this?
Bar.new.blah
# how do I do this?
Bar.blah
class Foo
def initialize(thing)
@thing = thing
end
def test_me
if @thing.big?
'Big!'
else
'Small!'
end
end
end
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
[1,2,3].each do |i|
puts i
end