From: <mjd...@us...> - 2009-11-24 19:34:54
|
Revision: 320 http://treebase.svn.sourceforge.net/treebase/?rev=320&view=rev Author: mjdominus Date: 2009-11-24 19:33:56 +0000 (Tue, 24 Nov 2009) Log Message: ----------- add a link table for link-attribute tests Modified Paths: -------------- trunk/treebase-core/src/main/perl/t/01_basic.t Added Paths: ----------- trunk/treebase-core/src/main/perl/23_link.t trunk/treebase-core/src/main/perl/test_db/person trunk/treebase-core/src/main/perl/test_db/study_author Added: trunk/treebase-core/src/main/perl/23_link.t =================================================================== --- trunk/treebase-core/src/main/perl/23_link.t (rev 0) +++ trunk/treebase-core/src/main/perl/23_link.t 2009-11-24 19:33:56 UTC (rev 320) @@ -0,0 +1,12 @@ +use Test::More tests => 1; + +# +# Tests for link attributes (%r2_attr) +# + +use_ok('CIPRES::TreeBase::TestObjects'); +use DBI; +my $dbh = DBI->connect("DBI:CSV:f_dir=test_db;csv_eol=\n"); +CIPRES::TreeBase::VeryBadORM->set_db_connection($dbh); + +ok(1); Modified: trunk/treebase-core/src/main/perl/t/01_basic.t =================================================================== --- trunk/treebase-core/src/main/perl/t/01_basic.t 2009-11-24 19:21:44 UTC (rev 319) +++ trunk/treebase-core/src/main/perl/t/01_basic.t 2009-11-24 19:33:56 UTC (rev 320) @@ -1,5 +1,5 @@ -use Test::More tests => 36; +use Test::More tests => 50; use_ok('DBI'); use_ok('DBD::CSV'); @@ -10,6 +10,8 @@ check_table('matrices', qw(matrix_id name n_rows study_id)); check_table('TREE', qw(TreeId name root_node_id)); check_table('node', qw(treenode_id tree_id left_child right_child data)); +check_table('person', qw(person_id last first)); +check_table('study_author', qw(study_id person_id role)); use_ok('CIPRES::TreeBase::TestObjects'); Added: trunk/treebase-core/src/main/perl/test_db/person =================================================================== --- trunk/treebase-core/src/main/perl/test_db/person (rev 0) +++ trunk/treebase-core/src/main/perl/test_db/person 2009-11-24 19:33:56 UTC (rev 320) @@ -0,0 +1,11 @@ +person_id,last,first +1,Aguilar,Juan +2,Tuc,Thieu +3,Coquand,Thierry +4,Balfour,Todd +5,Quincunx,Quentin +6,Sax,Sixto +7,Sargent,Septimus +8,Octavian,Otto +9,Nonne,Ian +10,Ten Eyck,Rutger Added: trunk/treebase-core/src/main/perl/test_db/study_author =================================================================== --- trunk/treebase-core/src/main/perl/test_db/study_author (rev 0) +++ trunk/treebase-core/src/main/perl/test_db/study_author 2009-11-24 19:33:56 UTC (rev 320) @@ -0,0 +1,14 @@ +study_id,person_id,role +1,1,Author +1,2,Editor +2,2,Author +2,3,Author +4,4,Author +5,5,Author +5,6,Author +5,7,Editor +7,7,Author +7,8,Editor +8,10,Author +8,8,Author +8,9,Author This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |