forked from pool/perl-XML-LibXSLT
This commit is contained in:
committed by
Git OBS Bridge
parent
17e94c10b4
commit
992a58c270
66
perl-XML-LibXSLT-wrongtest.diff
Normal file
66
perl-XML-LibXSLT-wrongtest.diff
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
--- t/10functions.t
|
||||||
|
+++ t/10functions.t
|
||||||
|
@@ -1,5 +1,5 @@
|
||||||
|
use Test;
|
||||||
|
-BEGIN { plan tests => 33 }
|
||||||
|
+BEGIN { plan tests => 31 }
|
||||||
|
use XML::LibXSLT;
|
||||||
|
|
||||||
|
{
|
||||||
|
@@ -86,56 +86,6 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-{
|
||||||
|
- # testcase by Elizabeth Mattijsen
|
||||||
|
- my $parser = XML::LibXML->new;
|
||||||
|
- my $xsltproc = XML::LibXSLT->new;
|
||||||
|
-
|
||||||
|
- my $xml = $parser->parse_string( <<'XML' );
|
||||||
|
-<html><head/></html>
|
||||||
|
-XML
|
||||||
|
- my $xslt = $parser->parse_string( <<'XSLT' );
|
||||||
|
-<xsl:stylesheet
|
||||||
|
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||||
|
- xmlns:foo="http://foo"
|
||||||
|
- version="1.0">
|
||||||
|
-<xsl:template match="/html">
|
||||||
|
- <html>
|
||||||
|
- <xsl:apply-templates/>
|
||||||
|
- </html>
|
||||||
|
-</xsl:template>
|
||||||
|
-<xsl:template match="/html/head">
|
||||||
|
- <head>
|
||||||
|
- <xsl:copy-of select="foo:custom()/foo"/>
|
||||||
|
- <xsl:apply-templates/>
|
||||||
|
- </head>
|
||||||
|
-</xsl:template>
|
||||||
|
-</xsl:stylesheet>
|
||||||
|
-XSLT
|
||||||
|
-
|
||||||
|
- my $aux = <<'XML';
|
||||||
|
-<bar>
|
||||||
|
- <y><foo>1st</foo></y>
|
||||||
|
- <y><foo>2nd</foo></y>
|
||||||
|
-</bar>
|
||||||
|
-XML
|
||||||
|
- {
|
||||||
|
- XML::LibXSLT->register_function(
|
||||||
|
- ('http://foo', 'custom') => sub { $parser->parse_string( $aux )->findnodes('//y') }
|
||||||
|
- );
|
||||||
|
- my $stylesheet = $xsltproc->parse_stylesheet($xslt);
|
||||||
|
- my $result = $stylesheet->transform($xml);
|
||||||
|
- ok ($result->serialize,qq(<?xml version="1.0"?>\n<html xmlns:foo="http://foo"><head><foo>1st</foo><foo>2nd</foo></head></html>\n));
|
||||||
|
- }
|
||||||
|
- {
|
||||||
|
- XML::LibXSLT->register_function(
|
||||||
|
- ('http://foo', 'custom') => sub { $parser->parse_string( $aux )->findnodes('//y')->[0]; });
|
||||||
|
- my $stylesheet = $xsltproc->parse_stylesheet($xslt);
|
||||||
|
- my $result = $stylesheet->transform($xml);
|
||||||
|
- ok ($result->serialize,qq(<?xml version="1.0"?>\n<html xmlns:foo="http://foo"><head><foo>1st</foo></head></html>\n));
|
||||||
|
- }
|
||||||
|
-}
|
||||||
|
-
|
||||||
|
{
|
||||||
|
my $parser = XML::LibXML->new;
|
||||||
|
my $xsltproc = XML::LibXSLT->new;
|
@@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Sep 30 15:18:53 CEST 2008 - anicka@suse.cz
|
||||||
|
|
||||||
|
- fix build (disable two tests that are wrong (with regard to XML
|
||||||
|
specification)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Feb 5 16:32:54 CET 2008 - anicka@suse.cz
|
Tue Feb 5 16:32:54 CET 2008 - anicka@suse.cz
|
||||||
|
|
||||||
|
@@ -2,18 +2,26 @@
|
|||||||
# spec file for package perl-XML-LibXSLT (Version 1.66)
|
# spec file for package perl-XML-LibXSLT (Version 1.66)
|
||||||
#
|
#
|
||||||
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
# This file and all modifications and additions to the pristine
|
|
||||||
# package are under the same license as the package itself.
|
|
||||||
#
|
#
|
||||||
|
# All modifications and additions to the file contributed by third parties
|
||||||
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
|
# upon. The license for this file, and modifications and additions to the
|
||||||
|
# file, is the same license as for the pristine package itself (unless the
|
||||||
|
# license for the pristine package is not an Open Source License, in which
|
||||||
|
# case the license is the MIT License). An "Open Source License" is a
|
||||||
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
# norootforbuild
|
# norootforbuild
|
||||||
|
|
||||||
|
|
||||||
Name: perl-XML-LibXSLT
|
Name: perl-XML-LibXSLT
|
||||||
BuildRequires: libxslt-devel perl-XML-LibXML
|
BuildRequires: libxslt-devel perl-XML-LibXML
|
||||||
Version: 1.66
|
Version: 1.66
|
||||||
Release: 1
|
Release: 53
|
||||||
Requires: perl = %{perl_version}
|
Requires: perl = %{perl_version}
|
||||||
AutoReqProv: on
|
AutoReqProv: on
|
||||||
Group: Development/Libraries/Perl
|
Group: Development/Libraries/Perl
|
||||||
@@ -21,6 +29,7 @@ License: Artistic License
|
|||||||
Url: http://www.cpan.org/modules/by-module/XML/
|
Url: http://www.cpan.org/modules/by-module/XML/
|
||||||
Summary: XML::LibXSLT Perl Module
|
Summary: XML::LibXSLT Perl Module
|
||||||
Source: XML-LibXSLT-%{version}.tar.bz2
|
Source: XML-LibXSLT-%{version}.tar.bz2
|
||||||
|
Patch: %{name}-wrongtest.diff
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
Requires: perl-XML-LibXML
|
Requires: perl-XML-LibXML
|
||||||
|
|
||||||
@@ -37,6 +46,7 @@ supported in version 0.9 of libxslt.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n XML-LibXSLT-%{version}
|
%setup -q -n XML-LibXSLT-%{version}
|
||||||
|
%patch
|
||||||
|
|
||||||
%build
|
%build
|
||||||
perl Makefile.PL
|
perl Makefile.PL
|
||||||
@@ -61,6 +71,9 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
/var/adm/perl-modules/%{name}
|
/var/adm/perl-modules/%{name}
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Sep 30 2008 anicka@suse.cz
|
||||||
|
- fix build (disable two tests that are wrong (with regard to XML
|
||||||
|
specification)
|
||||||
* Tue Feb 05 2008 anicka@suse.cz
|
* Tue Feb 05 2008 anicka@suse.cz
|
||||||
- update to 1.66
|
- update to 1.66
|
||||||
* sync the binary internals to those of XML::LibXML 1.66
|
* sync the binary internals to those of XML::LibXML 1.66
|
||||||
|
Reference in New Issue
Block a user