Class: ODDB::State::Drugs::TestPackageFacade

Inherits:
Test::Unit::TestCase
  • Object
show all
Defined in:
test/test_model/comparison.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) setup



84
85
86
87
88
89
90
# File 'test/test_model/comparison.rb', line 84

def setup
  pack1 = StubComparisonPackage.new(ODDB::Dose.new(5, 'Tabletten'), nil)
  pack2 = StubComparisonPackage.new(ODDB::Dose.new(5, 'Tabletten'), 374)
  original = StubComparisonPackage.new(ODDB::Dose.new(5, 'Tabletten'), nil)
  @pack1 = Compare::Comparison::PackageFacade.new(pack1, original)
  @pack2 = Compare::Comparison::PackageFacade.new(pack2, original)
end

- (Object) test_comparable



91
92
93
# File 'test/test_model/comparison.rb', line 91

def test_comparable
  assert_nothing_raised { @pack1 <=> @pack2 }
end