test/unit/bio/db/test_rebase.rb in bio-1.0.0 vs test/unit/bio/db/test_rebase.rb in bio-1.1.0
- old
+ new
@@ -1,43 +1,24 @@
#
# test/unit/bio/db/test_rebase.rb - Unit test for Bio::REBASE
#
-# Copyright:: Copyright (C) 2005 Trevor Wennblom <trevor@corevx.com>
-# License:: LGPL
+# Author:: Trevor Wennblom <mailto:trevor@corevx.com>
+# Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+# License:: The Ruby License
#
-# $Id: test_rebase.rb,v 1.2 2006/01/20 09:53:24 k Exp $
+# $Id: test_rebase.rb,v 1.5 2007/04/05 23:35:43 trevor Exp $
#
-#
-#--
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2 of the License, or (at your option) any later version.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-#++
-#
-#
require 'pathname'
libpath = Pathname.new(File.join(File.dirname(__FILE__), ['..'] * 4, 'lib')).cleanpath.to_s
$:.unshift(libpath) unless $:.include?(libpath)
require 'test/unit'
require 'bio/db/rebase'
-module Bio
- class TestREBASE < Test::Unit::TestCase
+module Bio #:nodoc:
+ class TestREBASE < Test::Unit::TestCase #:nodoc:
def setup
enzyme_data = <<END
#
# REBASE version 511 emboss_e.511
@@ -106,9 +87,14 @@
assert_equal(a['AarI'].supplier_names, ['Fermentas International Inc.'])
assert_equal(a['AarI'].pattern, 'CACCTGC')
assert_equal(a['AatI'].supplier_names, ['Toyobo Biochemicals'])
assert_equal(a['AatI'].suppliers, ['O'])
+
+ assert_equal(a.enzyme_name?('aasi'), true)
+ assert_equal(a.enzyme_name?('AarI'), true)
+ assert_equal(a.enzyme_name?('Aari'), true)
+ assert_equal(a.enzyme_name?('AbrI'), false)
end
end
end