>From a54a57c8c1a2ff5261e3bfc8127f9e07e18c0e26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ralf=20Cors=C3=A9pius?= <corsepiu@xxxxxxxxxxxxxxxxx> Date: Mon, 13 Apr 2015 13:48:37 +0200 Subject: Add 0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch (RHBZ #1211215, https://github.com/petdance/html-lint/issues/39) diff --git a/0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch b/0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch new file mode 100644 index 0000000..7f35291 --- /dev/null +++ b/0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch @@ -0,0 +1,46 @@ +From 503ad38530d6796fbef6fe74dd20d07b98e4143b Mon Sep 17 00:00:00 2001 +From: Andy Lester <andy@xxxxxxxxxxxx> +Date: Tue, 7 Apr 2015 09:57:09 -0500 +Subject: [PATCH] doc-tag-required errors are now sorted by tag name. + +--- + Changes | 9 +++++++++ + lib/HTML/Lint/Parser.pm | 2 +- + 2 files changed, 10 insertions(+), 1 deletion(-) + +diff --git a/Changes b/Changes +index 01f254c..3093c8a 100644 +--- a/Changes ++++ b/Changes +@@ -6,6 +6,15 @@ NOTE: All bugs and requests are now being handled through GitHub. + + Please DO NOT send bug reports to http://rt.cpan.org/. + ++NEXT ++ ++ [FIXES] ++ Errors of the type doc-tag-required did not come out in any defined ++ order. They are now sorted by tag name. This was discovered ++ because hash randomization caused tests to fail on Perl 5.18 and ++ above. Thanks, Slaven Rezic and Andrew Main. ++ ++ + 2.22 Mon Apr 6 15:47:11 CDT 2015 + [CHANGES THAT COULD BREAK YOUR CODE] + Previously, html_ok() would not check the entire structure of a web +diff --git a/lib/HTML/Lint/Parser.pm b/lib/HTML/Lint/Parser.pm +index aa1e337..5c60915 100644 +--- a/lib/HTML/Lint/Parser.pm ++++ b/lib/HTML/Lint/Parser.pm +@@ -102,7 +102,7 @@ sub _start_document { + sub _end_document { + my ($self,$line,$column) = @_; + +- for my $tag ( keys %isRequired ) { ++ for my $tag ( sort keys %isRequired ) { + if ( !$self->{_first_seen}->{$tag} ) { + $self->gripe( 'doc-tag-required', tag => $tag ); + } +-- +2.1.0 + diff --git a/perl-HTML-Lint.spec b/perl-HTML-Lint.spec index 1734fec..91e4411 100644 --- a/perl-HTML-Lint.spec +++ b/perl-HTML-Lint.spec @@ -1,11 +1,13 @@ Name: perl-HTML-Lint Version: 2.22 -Release: 1%{?dist} +Release: 2%{?dist} Summary: HTML::Lint Perl module License: Artistic 2.0 Group: Development/Libraries URL: http://search.cpan.org/dist/HTML-Lint/ Source0: http://www.cpan.org/authors/id/P/PE/PETDANCE/HTML-Lint-%{version}.tar.gz +# https://github.com/petdance/html-lint/commit/f5115c7 +Patch0: 0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch BuildArch: noarch BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(HTML::Parser) >= 3.47 @@ -31,6 +33,7 @@ legitmacy. %prep %setup -q -n HTML-Lint-%{version} +%patch0 -p1 %build %{__perl} Makefile.PL INSTALLDIRS=vendor @@ -54,6 +57,10 @@ make test %{_mandir}/man3/* %changelog +* Mon Apr 13 2015 Ralf Corsépius <corsepiu@xxxxxxxxxxxxxxxxx> - 2.22-2 +- Add 0001-doc-tag-required-errors-are-now-sorted-by-tag-name.patch + (RHBZ #1211215, https://github.com/petdance/html-lint/issues/39) + * Tue Apr 07 2015 Ralf Corsépius <corsepiu@xxxxxxxxxxxxxxxxx> - 2.22-1 - Upstream update. - Modernize spec. -- cgit v0.10.2 http://pkgs.fedoraproject.org/cgit/perl-HTML-Lint.git/commit/?h=f22&id=a54a57c8c1a2ff5261e3bfc8127f9e07e18c0e26
-- Fedora Extras Perl SIG http://www.fedoraproject.org/wiki/Extras/SIGs/Perl perl-devel mailing list perl-devel@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/perl-devel