$fh->close;
my $dsn = "dbi:SQLite:dbname=$file";
my $uuid;
+my $user = 'user@example.org';
my $t = Text::Tradition->new(
'name' => 'inline',
'input' => 'Tabular',
$uuid = $d->save( $t );
ok( $uuid, "Saved test tradition" );
+ # Add a test user
+ my $user = $d->add_user({ username => $user, password => 'UserPass' });
+ $user->add_tradition( $t );
+ $d->store( $user );
+ is( $t->user, $user, "Assigned tradition to test user" );
+
SKIP: {
skip "Analysis package not installed", 5 unless $stemma_enabled;
my $s = $t->add_stemma( dotfile => 't/data/simple.dot' );
is( scalar $f->traditionlist, 1, "Object is deleted from index" );
}
-TODO: {
- todo_skip "Deletion conflicts with Analysis package", 2
- if $t->does('Text::Tradition::HasStemma');
+{
my $g = Text::Tradition::Directory->new( 'dsn' => $dsn );
my $scope = $g->new_scope;
is( scalar $g->traditionlist, 1, "Now one object in new directory index" );
$fh->close;
my $dsn = "dbi:SQLite:dbname=$file";
my $uuid;
+my $user = 'user@example.org';
my $t = Text::Tradition->new(
'name' => 'inline',
'input' => 'Tabular',
$uuid = $d->save( $t );
ok( $uuid, "Saved test tradition" );
+ # Add a test user
+ my $user = $d->add_user({ username => $user, password => 'UserPass' });
+ $user->add_tradition( $t );
+ $d->store( $user );
+ is( $t->user, $user, "Assigned tradition to test user" );
+
SKIP: {
skip "Analysis package not installed", 5 unless $stemma_enabled;
my $s = $t->add_stemma( dotfile => 't/data/simple.dot' );
is( scalar $f->traditionlist, 1, "Object is deleted from index" );
}
-TODO: {
- todo_skip "Deletion conflicts with Analysis package", 2
- if $t->does('Text::Tradition::HasStemma');
+{
my $g = Text::Tradition::Directory->new( 'dsn' => $dsn );
my $scope = $g->new_scope;
is( scalar $g->traditionlist, 1, "Now one object in new directory index" );