File Coverage

blib/lib/Test/Attean/MutableETagCacheableQuadStore.pm
Criterion Covered Total %
statement 17 17 100.0
branch n/a
condition n/a
subroutine 6 6 100.0
pod n/a
total 23 23 100.0


line stmt bran cond sub pod time code
1              
2             use v5.14;
3 1     1   702 use warnings;
  1         4  
4 1     1   5 use Test::Roo::Role;
  1         2  
  1         31  
5 1     1   5 use Test::Moose;
  1         3  
  1         9  
6 1     1   1094 use Attean;
  1         3  
  1         9  
7 1     1   560 use Attean::RDF;
  1         3  
  1         9  
8 1     1   4  
  1         2  
  1         8  
9             requires 'create_store'; # create_store( quads => \@quads )
10             with 'Test::Attean::ETagCacheableQuadStore';
11              
12             test 'mutable etagcacheablequadstore' => sub {
13             my $self = shift;
14             my $q1 = quad(iri('s'), iri('p'), iri('o'), iri('g'));
15             my $q2 = quad(iri('x'), iri('y'), iri('z'), iri('g'));
16             my $store = $self->create_store(quads => [$q1, $q2]);
17             my $start = $store->etag_value_for_quads();
18             $store->remove_quad($q1);
19             my $end = $store->etag_value_for_quads();
20             isnt($start, $end, "etag changed after update ($start => $end)");
21             $self->cleanup_store($store);
22             };
23              
24             1;