fedora-migrator /vendor/gems/facets-2.4.5/test/more/test_snapshot.rb

Language Ruby Lines 22
MD5 Hash 15c606985485dce516885e69e9204310 Estimated Cost $306 (why?)
Repository https://bitbucket.org/mediashelf/fedora-migrator View Raw File
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
# Test lib/facets/snapshot.rb

require 'facets/snapshot.rb'
require 'test/unit'

class TC_Snapshot < Test::Unit::TestCase

  def setup
    customer = Struct.new(:name, :address, :zip)
    joe = customer.new( "Joe Pitare", "1115 Lila Ln.", 47634 )
    @joe_snap = joe.take_snapshot
  end

  def test_storage
    assert_equal( "Joe Pitare", @joe_snap[:name]  )
    assert_equal( "1115 Lila Ln.", @joe_snap[:address] )
    assert_equal( 47634, @joe_snap[:zip] )
  end

end
Back to Top