diff options
author | dakkar <dakkar@luxion> | 2006-02-07 16:05:07 +0000 |
---|---|---|
committer | dakkar <dakkar@luxion> | 2006-02-07 16:05:07 +0000 |
commit | 949d67328079c86ea136a1626cef7f7fa4041d12 (patch) | |
tree | 531c4f9c7481a26f15933f3cc318a110a0b49b8f | |
parent | aggiunte letture da fh, anche lazy (diff) | |
download | WebCoso-949d67328079c86ea136a1626cef7f7fa4041d12.tar.gz WebCoso-949d67328079c86ea136a1626cef7f7fa4041d12.tar.bz2 WebCoso-949d67328079c86ea136a1626cef7f7fa4041d12.zip |
aggiornato Config con i nuovi fh lazy
git-svn-id: svn://luxion/repos/WebCoso/trunk@156 fcb26f47-9200-0410-b104-b98ab5b095f3
-rw-r--r-- | lib/WebCoso/Config.pm | 2 | ||||
-rw-r--r-- | t/01-config.t | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/WebCoso/Config.pm b/lib/WebCoso/Config.pm index ab62179..ebc3c75 100644 --- a/lib/WebCoso/Config.pm +++ b/lib/WebCoso/Config.pm @@ -108,7 +108,7 @@ sub res { for my $filename (@abs_source_files) { $resource->set_property( {filename=>$filename}, - datastream => _open_file($filename), + datastream => sub{_open_file($filename)}, ); } diff --git a/t/01-config.t b/t/01-config.t index 79bca63..4fee455 100644 --- a/t/01-config.t +++ b/t/01-config.t @@ -29,7 +29,7 @@ is_deeply( [$resources[0]->get_axis_values('filename')], ["$thisdir/src/file1.rest.txt"], 'filename'); -my $content=do {my $fh=$resources[0]->get_property({filename=>"$thisdir/src/file1.rest.txt"},'datastream');local $/;<$fh>}; +my $content=$resources[0]->get_property_string({filename=>"$thisdir/src/file1.rest.txt"},'datastream'); is($content, <<'EOF',''); Titolo |