Hello community, here is the log from the commit of package perl-SVG for openSUSE:Factory checked in at 2012-05-29 11:45:41 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/perl-SVG (Old) and /work/SRC/openSUSE:Factory/.perl-SVG.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-SVG", Maintainer is "" Changes: -------- --- /work/SRC/openSUSE:Factory/perl-SVG/perl-SVG.changes 2011-11-21 12:46:27.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.perl-SVG.new/perl-SVG.changes 2012-05-29 11:46:23.000000000 +0200 @@ -1,0 +2,9 @@ +Mon May 28 13:59:37 UTC 2012 - co...@suse.com + +- updated to 2.51 + - Maintenance by Gabor Szabo + - Some documentation fixes. + - Modernizing test suite. + - Link to new public repository. + +------------------------------------------------------------------- Old: ---- SVG-2.50.tar.gz New: ---- SVG-2.51.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ perl-SVG.spec ++++++ --- /var/tmp/diff_new_pack.osxsJ1/_old 2012-05-29 11:46:25.000000000 +0200 +++ /var/tmp/diff_new_pack.osxsJ1/_new 2012-05-29 11:46:25.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package perl-SVG # -# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -15,31 +15,26 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # -# norootforbuild - -%bcond_with pod Name: perl-SVG +Version: 2.51 +Release: 0 %define cpan_name SVG Summary: Perl extension for generating Scalable Vector Graphics (SVG) documents -Version: 2.50 -Release: 1 -License: GPL-1.0+ or Artistic-1.0 +License: Artistic-1.0 or GPL-1.0+ Group: Development/Libraries/Perl Url: http://search.cpan.org/dist/SVG/ -#Source: http://www.cpan.org/modules/by-module/SVG/SVG-%{version}.tar.gz -Source: %{cpan_name}-%{version}.tar.gz +Source: http://www.cpan.org/authors/id/S/SZ/SZABGAB/%{cpan_name}-%{version}.tar.gz BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build -%{perl_requires} BuildRequires: perl BuildRequires: perl-macros -%if %{with pod} -BuildRequires: perl(Test::Pod) >= 1.00 -BuildRequires: perl(Test::Pod::Coverage) -%endif -BuildRequires: perl(Scalar::Util) -Requires: perl(Scalar::Util) +#BuildRequires: perl(SVG) +#BuildRequires: perl(SVG::DOM) +#BuildRequires: perl(SVG::Element) +#BuildRequires: perl(SVG::Extension) +#BuildRequires: perl(SVG::XML) +%{perl_requires} %description SVG is a 100% Perl module which generates a nested data structure @@ -48,12 +43,11 @@ into it, access the DOM object, create and access javascript, and generate SMIL animation content. -Authors: --------- - Ronan Oger <ro...@cpan.com> +Refer to the SVG::Manual manpage for the complete manual. %prep %setup -q -n %{cpan_name}-%{version} +find . -type f -print0 | xargs -0 chmod 644 %build %{__perl} Makefile.PL INSTALLDIRS=vendor @@ -64,18 +58,11 @@ %install %perl_make_install -# do not perl_process_packlist (noarch) -# remove .packlist file -%{__rm} -rf $RPM_BUILD_ROOT%perl_vendorarch -# remove perllocal.pod file -%{__rm} -rf $RPM_BUILD_ROOT%perl_archlib +%perl_process_packlist %perl_gen_filelist -%clean -%{__rm} -rf $RPM_BUILD_ROOT - %files -f %{name}.files -%defattr(-,root,root,-) -%doc Changes LICENSE README +%defattr(-,root,root,755) +%doc Changes examples LICENSE README %changelog ++++++ SVG-2.50.tar.gz -> SVG-2.51.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/Changes new/SVG-2.51/Changes --- old/SVG-2.50/Changes 2010-04-07 16:37:29.000000000 +0200 +++ new/SVG-2.51/Changes 2012-03-30 07:47:39.000000000 +0200 @@ -1,5 +1,10 @@ Revision history for Perl extension SVG. + - Maintenance by Gabor Szabo + - Some documentation fixes. + - Modernizing test suite. + - Link to new public repository. + 2.50 05 April, 2010 -Fixed inline SVG generation method (bug # 43814 and 50075) -Fixed XML-escaped characters (bug # 53918 and 44454) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/MANIFEST new/SVG-2.51/MANIFEST --- old/SVG-2.50/MANIFEST 2009-01-09 23:32:05.000000000 +0100 +++ new/SVG-2.51/MANIFEST 2012-03-30 08:28:40.000000000 +0200 @@ -1,4 +1,4 @@ -META.yml +Changes examples/attributeManip.pl examples/image_sample.pl examples/inline_sample.pl @@ -19,11 +19,9 @@ lib/SVG/XML.pm LICENSE Makefile.PL -MANIFEST +MANIFEST This list of files README -Changes t/01-loadsvg.t -t/02-simpledoc.t t/03-render.t t/04-inline.t t/05-processinginstruction.t @@ -48,3 +46,5 @@ t/24-doubleuse.t t/98_all_pod.t t/99_test_pod_coverage.t +META.yml Module YAML meta-data (added by MakeMaker) +META.json Module JSON meta-data (added by MakeMaker) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/META.json new/SVG-2.51/META.json --- old/SVG-2.50/META.json 1970-01-01 01:00:00.000000000 +0100 +++ new/SVG-2.51/META.json 2012-03-30 08:28:40.000000000 +0200 @@ -0,0 +1,46 @@ +{ + "abstract" : "Perl extension for generating Scalable Vector Graphics (SVG) documents", + "author" : [ + "Ronan Oger <ro...@cpan.com>" + ], + "dynamic_config" : 1, + "generated_by" : "ExtUtils::MakeMaker version 6.62, CPAN::Meta::Converter version 2.112150", + "license" : [ + "perl_5" + ], + "meta-spec" : { + "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec", + "version" : "2" + }, + "name" : "SVG", + "no_index" : { + "directory" : [ + "t", + "inc" + ] + }, + "prereqs" : { + "build" : { + "requires" : { + "ExtUtils::MakeMaker" : 0 + } + }, + "configure" : { + "requires" : { + "ExtUtils::MakeMaker" : 0 + } + }, + "runtime" : { + "requires" : { + "Scalar::Util" : 0 + } + } + }, + "release_status" : "stable", + "resources" : { + "repository" : { + "url" : "https://github.com/szabgab/SVG" + } + }, + "version" : "2.51" +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/META.yml new/SVG-2.51/META.yml --- old/SVG-2.50/META.yml 2010-04-07 16:39:30.000000000 +0200 +++ new/SVG-2.51/META.yml 2012-03-30 08:28:40.000000000 +0200 @@ -1,22 +1,24 @@ ---- #YAML:1.0 -name: SVG -version: 2.50 -abstract: Perl extension for generating Scalable Vector Graphics (SVG) documents +--- +abstract: 'Perl extension for generating Scalable Vector Graphics (SVG) documents' author: - - Ronan Oger <ro...@cpan.com> -license: perl -distribution_type: module -configure_requires: - ExtUtils::MakeMaker: 0 + - 'Ronan Oger <ro...@cpan.com>' build_requires: - ExtUtils::MakeMaker: 0 -requires: - Scalar::Util: ~ -no_index: - directory: - - t - - inc -generated_by: ExtUtils::MakeMaker version 6.55_02 + ExtUtils::MakeMaker: 0 +configure_requires: + ExtUtils::MakeMaker: 0 +dynamic_config: 1 +generated_by: 'ExtUtils::MakeMaker version 6.62, CPAN::Meta::Converter version 2.112150' +license: perl meta-spec: - url: http://module-build.sourceforge.net/META-spec-v1.4.html - version: 1.4 + url: http://module-build.sourceforge.net/META-spec-v1.4.html + version: 1.4 +name: SVG +no_index: + directory: + - t + - inc +requires: + Scalar::Util: 0 +resources: + repository: https://github.com/szabgab/SVG +version: 2.51 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/Makefile.PL new/SVG-2.51/Makefile.PL --- old/SVG-2.50/Makefile.PL 2010-04-05 15:16:31.000000000 +0200 +++ new/SVG-2.51/Makefile.PL 2012-03-30 07:45:21.000000000 +0200 @@ -4,9 +4,16 @@ WriteMakefile( NAME => 'SVG', VERSION_FROM => 'lib/SVG.pm', # finds $VERSION - PREREQ_PM => { 'Scalar::Util' }, + PREREQ_PM => { + 'Scalar::Util' => 0, + }, ($] >= 5.005 ? ## Add these new keywords supported since 5.005 (ABSTRACT_FROM => 'lib/SVG/Manual.pm', # retrieve abstract from module LICENSE => 'perl', AUTHOR => 'Ronan Oger <ro...@cpan.com>') : ()), + META_MERGE => { + resources => { + repository => 'https://github.com/szabgab/SVG', + }, + }, ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG/DOM.pm new/SVG-2.51/lib/SVG/DOM.pm --- old/SVG-2.50/lib/SVG/DOM.pm 2010-04-07 16:36:28.000000000 +0200 +++ new/SVG-2.51/lib/SVG/DOM.pm 2012-03-30 08:23:11.000000000 +0200 @@ -1,9 +1,10 @@ package SVG::DOM; use strict; use warnings; + use Scalar::Util qw/weaken/; -use vars qw($VERSION); -$VERSION = "2.50"; + +our $VERSION = "2.51"; # this module extends SVG::Element package SVG::Element; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG/Element.pm new/SVG-2.51/lib/SVG/Element.pm --- old/SVG-2.50/lib/SVG/Element.pm 2010-04-07 09:45:53.000000000 +0200 +++ new/SVG-2.51/lib/SVG/Element.pm 2012-03-30 08:24:50.000000000 +0200 @@ -20,15 +20,18 @@ package SVG::Element; -$VERSION = "2.50"; use strict; +use warnings; + use SVG::XML; use SVG::DOM; use SVG::Extension; use Scalar::Util qw/weaken/; -use warnings; -use vars qw($AUTOLOAD %autosubs); + +our $AUTOLOAD; + +our $VERSION = "2.51"; my @autosubs = qw( animateMotion animateColor animateTransform circle ellipse rect polyline @@ -42,7 +45,7 @@ image a g ); -%autosubs = map { $_ => 1 } @autosubs; +our %autosubs = map { $_ => 1 } @autosubs; #------------------------------------------------------------------------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG/Extension.pm new/SVG-2.51/lib/SVG/Extension.pm --- old/SVG-2.50/lib/SVG/Extension.pm 2010-04-05 13:40:51.000000000 +0200 +++ new/SVG-2.51/lib/SVG/Extension.pm 2012-03-30 08:26:21.000000000 +0200 @@ -1,8 +1,8 @@ package SVG::Extension; use strict; use warnings; -use vars qw(@ISA $VERSION @TYPES %TYPES); -$VERSION = "2.50"; + +our $VERSION = "2.51"; # although DTD declarations are not elements, we use the same API so we can # manipulate the internal DTD subset using the same methods available for @@ -11,7 +11,7 @@ # e.g. isElementDecl() to determine types; this API will be retained # irrespective. -@ISA=qw(SVG::Element); +our @ISA = qw(SVG::Element); # DTD declarations handled in this module use constant ELEMENT => "ELEMENT"; @@ -19,8 +19,8 @@ use constant NOTATION => "NOTATION"; use constant ENTITY => "ENTITY"; -@TYPES=(ELEMENT,ATTLIST,NOTATION,ENTITY); -%TYPES=map { $_ => 1 } @TYPES; +our @TYPES = (ELEMENT,ATTLIST,NOTATION,ENTITY); +our %TYPES = map { $_ => 1 } @TYPES; #----------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG/Manual.pm new/SVG-2.51/lib/SVG/Manual.pm --- old/SVG-2.50/lib/SVG/Manual.pm 2010-04-06 15:08:10.000000000 +0200 +++ new/SVG-2.51/lib/SVG/Manual.pm 2012-03-30 08:27:40.000000000 +0200 @@ -1,11 +1,8 @@ package SVG::Manual; - -our $VERSION = 2.50; -use vars qw($VERSION); use strict; use warnings; -$VERSION = eval $VERSION; +our $VERSION = 2.51; =head1 NAME @@ -13,7 +10,7 @@ =head2 VERSION -Covers SVG-2.47 distribution, December 2008 +Covers SVG-2.51 distribution, 30 March 2012 =head1 SYNOPSIS @@ -188,7 +185,7 @@ The Default SVG tag will generate the following XML: - $svg = new SVG; + $svg = SVG->new; print $svg->xmlify; Resulting XML snippet: @@ -223,8 +220,6 @@ =head1 EXAMPLES -http://wiki.roitsystems.com/ - See also the examples directory in this distribution which contain several fully documented examples. =pod @@ -255,11 +250,11 @@ B<Example:> - my $svg1=new SVG; + my $svg1 = SVG->new; - my $svg2=new SVG(id => 'document_element'); + my $svg2 = SVG->new(id => 'document_element'); - my $svg3=new SVG(s + my $svg3 = SVG->new(s -printerror => 1, -raiseerror => 0, -indent => ' ', @@ -492,8 +487,8 @@ %$points, id=>'pline_1', style=>{ - 'fill-opacity'=>0, - 'stroke-color'=>'rgb(250,123,23)' + 'fill-opacity' => 0, + 'stroke' => 'rgb(250,123,23)' } ); @@ -643,8 +638,8 @@ id => 'pline_1', style => { 'fill-opacity' => 0, - 'fill-color' => 'green', - 'stroke-color' => 'rgb(250,123,23)' + 'fill' => 'green', + 'stroke' => 'rgb(250,123,23)' } ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG/XML.pm new/SVG-2.51/lib/SVG/XML.pm --- old/SVG-2.50/lib/SVG/XML.pm 2010-04-06 13:35:30.000000000 +0200 +++ new/SVG-2.51/lib/SVG/XML.pm 2012-03-30 08:19:53.000000000 +0200 @@ -21,13 +21,11 @@ use strict; use warnings; -use vars qw($VERSION @ISA @EXPORT ); +use Exporter qw(import); -$VERSION = "2.50"; +our $VERSION = "2.51"; -require Exporter; -@ISA = qw(Exporter); -@EXPORT = qw( +our @EXPORT = qw( xmlesc xmlescape xmlescp diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/lib/SVG.pm new/SVG-2.51/lib/SVG.pm --- old/SVG-2.50/lib/SVG.pm 2010-04-06 17:05:55.000000000 +0200 +++ new/SVG-2.51/lib/SVG.pm 2012-03-30 08:19:46.000000000 +0200 @@ -1,4 +1,4 @@ -=pod +=pod =head1 NAME @@ -9,25 +9,24 @@ package SVG; use strict; -use vars qw($VERSION @ISA $AUTOLOAD); -use Exporter; +use warnings; + use SVG::XML; use SVG::Element; use SVG::Extension; use Scalar::Util qw/weaken/; -use warnings; -@ISA = qw(SVG::Element SVG::Extension); +our @ISA = qw(SVG::Element SVG::Extension); -$VERSION = "2.50"; +our $VERSION = "2.51"; #------------------------------------------------------------------------------- -=pod +=pod =head2 VERSION -Version 2.44, 08 April, 2008 +Version 2.51, 30 March, 2012 Refer to L<SVG::Manual> for the complete manual @@ -42,7 +41,11 @@ =head1 AUTHOR -Ronan Oger, RO IT Systemms GmbH, c...@roitsystems.com.com +Ronan Oger, RO IT Systemms GmbH, c...@roitsystems.com + +=head1 CO-MAINTAINER + +Gabor Szabo =head1 CREDITS @@ -153,11 +156,11 @@ B<Example:> - my $svg1=new SVG; + my $svg1 = SVG->new; - my $svg2=new SVG(id => 'document_element'); + my $svg2 = SVG->new(id => 'document_element'); - my $svg3=new SVG( + my $svg3 = SVG->new( -printerror => 1, -raiseerror => 0, -indent => ' ', diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/01-loadsvg.t new/SVG-2.51/t/01-loadsvg.t --- old/SVG-2.50/t/01-loadsvg.t 2008-04-09 22:24:46.000000000 +0200 +++ new/SVG-2.51/t/01-loadsvg.t 2012-03-30 07:49:07.000000000 +0200 @@ -1,4 +1,9 @@ -use Test::More tests => 1; use strict; +use warnings; + +use Test::More tests => 2; use_ok ('SVG',"Use SVG"); + +my $svg = SVG->new; +isa_ok $svg, 'SVG'; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/02-simpledoc.t new/SVG-2.51/t/02-simpledoc.t --- old/SVG-2.50/t/02-simpledoc.t 2008-04-09 22:25:02.000000000 +0200 +++ new/SVG-2.51/t/02-simpledoc.t 1970-01-01 01:00:00.000000000 +0100 @@ -1,4 +0,0 @@ -use Test::More tests => 1; -use strict; -use SVG; -ok(my $svg=new SVG,"Constructor"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/03-render.t new/SVG-2.51/t/03-render.t --- old/SVG-2.50/t/03-render.t 2008-04-14 22:40:55.000000000 +0200 +++ new/SVG-2.51/t/03-render.t 2012-03-30 07:49:04.000000000 +0200 @@ -1,9 +1,15 @@ -use Test::More tests=>3; use strict; +use warnings; + +use Test::More tests => 4; use SVG; -my $svg=new SVG; -ok($svg->circle(),"add circle"); -ok(my $output=$svg->render(),"render"); -ok($output,"nonempty output"); +my $svg = SVG->new; +diag "add circle"; +my $e = $svg->circle(); +isa_ok $e, 'SVG::Element'; +my $output = $svg->render(); +ok($output, "nonempty output of render"); +like $output, qr{<\?xml version="1.0" encoding="UTF-8" standalone="yes"\?>}; +like $output, qr{<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">}; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/04-inline.t new/SVG-2.51/t/04-inline.t --- old/SVG-2.50/t/04-inline.t 2010-04-06 13:42:12.000000000 +0200 +++ new/SVG-2.51/t/04-inline.t 2012-03-30 07:49:34.000000000 +0200 @@ -1,27 +1,30 @@ -use Test::More tests=>9; use strict; +use warnings; + +use Test::More tests => 10; use SVG qw(-inline 1); # test: -inline -ok(my $svg1=new SVG(),"inline constructor"); -$svg1->text->cdata("An inline document"); +my $svg1 = SVG->new(); +isa_ok $svg1, 'SVG'; +isa_ok $svg1->text->cdata("An inline document"), 'SVG::Element'; -my $xml1a=$svg1->render(); -ok($xml1a!~/DOCTYPE/,"1 render inline document"); -ok($xml1a!~/^<\?xml .*?\?>\s*/sm); +my $xml1a = $svg1->render(); +unlike $xml1a, qr/DOCTYPE/, "1 render inline document"; +unlike $xml1a, qr/^<\?xml .*?\?>\s*/sm; -my $xml1b=$svg1->render(-inline => 0); -ok($xml1b =~ /DOCTYPE/,"2 render not inline"); -ok($xml1b =~ /^<\?xml .*?\?>\s*/sm); +my $xml1b = $svg1->render(-inline => 0); +like $xml1b, qr/DOCTYPE/, "2 render not inline"; +like $xml1b, qr/^<\?xml .*?\?>\s*/sm; -my $svg2=new SVG(-inline => 0); +my $svg2 = SVG->new(-inline => 0); -my $xml2a=$svg2->render(); -ok($xml2a=~/DOCTYPE/,"3 render for not inline"); -ok($xml2a=~/^<\?xml .*?\?>\s*/sm); +my $xml2a = $svg2->render(); +like $xml2a, qr/DOCTYPE/, "3 render for not inline"; +like $xml2a, qr/^<\?xml .*?\?>\s*/sm; -my $xml2b=$svg2->render(-inline => 1); -ok($xml2b!~/DOCTYPE/,"4 render inline render"); -ok($xml2b!~/^<\?xml .*?\?>\s*/sm); +my $xml2b = $svg2->render(-inline => 1); +unlike $xml2b, qr/DOCTYPE/, "4 render inline render"; +unlike $xml2b, qr/^<\?xml .*?\?>\s*/sm; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/05-processinginstruction.t new/SVG-2.51/t/05-processinginstruction.t --- old/SVG-2.50/t/05-processinginstruction.t 2008-04-13 15:38:25.000000000 +0200 +++ new/SVG-2.51/t/05-processinginstruction.t 2012-03-30 07:55:47.000000000 +0200 @@ -1,27 +1,34 @@ -use Test::More tests=>9; use strict; +use warnings; + +use Test::More tests => 9; use SVG; -my $svg=new SVG(width=>100,height=>100); -my $xml; +my $svg = SVG->new(width=>100,height=>100); + +my $pi = $svg->pi("Hello world","I am a PI"); +ok($pi,"PI: add 2 arbitrary processing instructions"); -ok(my $pi = $svg->pi("Hello world","I am a PI"),"PI: add 2 arbitrary processing instructions"); ok($svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'),"add a drawing element"); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -$svg->rect(x=>0,y=>0,width=>10,height=>10,fill=>'red',stroke=>'brick'); -ok($xml = $svg->xmlify(),"serialize the svg"); -ok($xml=~/<\?Hello\sworld\?>/gs, "serialize arbitrary processing instruction 1"); -ok($xml=~/<\?I\sam\sa\sPI\?>/gs, "serialize arbitrary processing instruction 2"); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); +$svg->rect(x=>0, y=>0, width=>10, height=>10, fill=>'red', stroke=>'brick'); + +my $xml = $svg->xmlify(); +ok($xml, "serialize the svg"); +like($xml, qr/<\?Hello\sworld\?>/, "serialize arbitrary processing instruction 1"); +like($xml, qr/<\?I\sam\sa\sPI\?>/, "serialize arbitrary processing instruction 2"); -ok($xml=~/rect/gsi,"PI 2: add non-PI elements"); -ok(scalar @{$svg->pi} == 2,"PI 3 - fetch PI array"); + +like($xml, qr/rect/, "PI 2: add non-PI elements"); +is(scalar @{$svg->pi}, 2,"PI 3 - fetch PI array"); $svg->pi("Third PI entry"); $xml = $svg->xmlify(); -ok($xml=~/<\?Third\sPI\sentry\?>/gsi,"pi 2"); -ok(scalar @{$svg->pi} == 3,"PI 3"); +like($xml, qr/<\?Third\sPI\sentry\?>/, "pi 2"); +is(scalar @{$svg->pi}, 3, "PI 3"); + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/06-doctype.t new/SVG-2.51/t/06-doctype.t --- old/SVG-2.50/t/06-doctype.t 2008-04-11 10:01:59.000000000 +0200 +++ new/SVG-2.51/t/06-doctype.t 2012-03-30 08:01:17.000000000 +0200 @@ -1,32 +1,39 @@ -use Test::More tests=>8; - use strict; +use warnings; + +use Test::More tests => 8; + use SVG (); # test: -sysid -pubid -docroot -my $svg=new SVG(); -my $xml; +my $svg = SVG->new(); $svg->text->cdata("Document type declaration test"); -ok($xml=$svg->dtddecl(),"dtd reclaration"); +my $xml = $svg->dtddecl(); -ok( $xml=~/DOCTYPE svg /,"doctype found"); -ok($xml=~/ PUBLIC "-\/\/W3C\/\/DTD SVG 1.0\/\/EN" /,"PUBLIC found"); -ok($xml=~/ "http:\/\/www.w3.org\/TR\/2001\/REC-SVG-20010904\/DTD\/svg10.dtd">/,"SVG 1.0 TR"); +ok($xml, "dtd reclaration"); -$svg=new SVG(-docroot => "mysvg"); -$xml=$svg->dtddecl(); -ok($xml=~/DOCTYPE mysvg /,"DOCTYPE mysvg"); +like($xml, qr/DOCTYPE svg /, "doctype found"); +like($xml, qr{ PUBLIC "-//W3C//DTD SVG 1.0//EN" }, "PUBLIC found"); +like($xml, qr{ "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">}, "SVG 1.0 TR"); -$svg=new SVG(-pubid => "-//ROIT Systems/DTD MyCustomDTD 1.0//EN"); +$svg = SVG->new(-docroot => "mysvg"); $xml=$svg->dtddecl(); -ok( $xml=~/ PUBLIC "-\/\/ROIT Systems\/DTD MyCustomDTD 1\.0\/\/EN" /,"pubid 2"); -$svg=new SVG(-pubid => undef); -$xml=$svg->dtddecl(); -ok( $xml=~/ SYSTEM "http:\/\/www.w3.org\/TR\/2001\/REC-SVG-20010904\/DTD\/svg10.dtd">/,"pubid 3"); +like($xml, qr/DOCTYPE mysvg /, "DOCTYPE mysvg"); + +$svg = SVG->new(-pubid => "-//ROIT Systems/DTD MyCustomDTD 1.0//EN"); + +$xml = $svg->dtddecl(); +like($xml, qr{ PUBLIC "-//ROIT Systems/DTD MyCustomDTD 1.0//EN" }, "pubid 2"); + +$svg = SVG->new(-pubid => undef); +$xml = $svg->dtddecl(); + +like($xml, qr{ SYSTEM "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">}, "pubid 3"); + +$svg = SVG->new(-sysid => "http://www.perlsvg.com/svg/my_custom_svg10.dtd"); +$xml = $svg->dtddecl(); +like($xml, qr{ "http://www.perlsvg.com/svg/my_custom_svg10.dtd">}, "custom sysid"); -$svg=new SVG(-sysid => "http://www.perlsvg.com/svg/my_custom_svg10.dtd"); -$xml=$svg->dtddecl(); -ok($xml=~/ "http:\/\/www\.perlsvg\.com\/svg\/my_custom_svg10.dtd">/,"custom sysid"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/07-extension.t new/SVG-2.51/t/07-extension.t --- old/SVG-2.50/t/07-extension.t 2008-04-11 10:02:52.000000000 +0200 +++ new/SVG-2.51/t/07-extension.t 2012-03-30 08:02:46.000000000 +0200 @@ -1,9 +1,11 @@ -use Test::More tests=>1; use strict; +use warnings; + +use Test::More tests=>1; use SVG; -my $svg=new SVG(-extension => "<!ENTITY % myentity \"myvalue\">"); +my $svg = SVG->new(-extension => q{<!ENTITY % myentity "myvalue">}); $svg->group->text->cdata("Extensions"); -my $xml=$svg->render; +my $xml = $svg->render; - ok($xml=~/[\n<!ENTITY % myentity "myvalue">\n]>/,"ENTITY myentity myvalue"); +like($xml, qr/[\n<!ENTITY % myentity "myvalue">\n]>/, "ENTITY myentity myvalue"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/SVG-2.50/t/08-looknfeel.t new/SVG-2.51/t/08-looknfeel.t --- old/SVG-2.50/t/08-looknfeel.t 2008-04-14 21:52:42.000000000 +0200 +++ new/SVG-2.51/t/08-looknfeel.t 2012-03-30 08:04:59.000000000 +0200 @@ -1,12 +1,16 @@ -use Test::More tests=> 2; use strict; +use warnings; + +use Test::More tests=> 2; use SVG (-indent => '*', -elsep => '|', -nocredits => 1); # test: -indent -elsep -nocredits -my $svg=new SVG(); +my $svg = SVG->new(); $svg->group->text->cdata("Look and Feel"); -my $xml=$svg->render(); -ok($xml=~/\n/ or$xml=~/\|/,"correct element separation"); -ok($xml=~/\*\*/ , "correct indent string"); +my $xml = $svg->render(); + +like($xml, qr/\n|\|/, "correct element separation"); +like($xml, qr/\*\*/ , "correct indent string"); + -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org