From 893d698148880b804275a72c2c71ec3c2e7c9a00 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 21 Feb 2020 11:43:42 +0100 Subject: add upstream patch for test suite --- 68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch | 32 ++++++++++++++++++++++++++ php-pecl-cmark.spec | 15 ++++++++---- 2 files changed, 43 insertions(+), 4 deletions(-) create mode 100644 68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch diff --git a/68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch b/68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch new file mode 100644 index 0000000..95b9ef9 --- /dev/null +++ b/68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch @@ -0,0 +1,32 @@ +From 68dc8c677e43e8431f8a109a289d3a4c5195e0f3 Mon Sep 17 00:00:00 2001 +From: Joe Watkins +Date: Sat, 25 May 2019 10:01:22 +0200 +Subject: [PATCH] fix test for XML render (do not depend on format) + +--- + tests/Render/XML/001.phpt | 12 ++++-------- + 1 file changed, 4 insertions(+), 8 deletions(-) + +diff --git a/tests/Render/XML/001.phpt b/tests/Render/XML/001.phpt +index 2041046..ed21905 100644 +--- a/tests/Render/XML/001.phpt ++++ b/tests/Render/XML/001.phpt +@@ -9,14 +9,10 @@ $document = new CommonMark\Node\Document; + $document->appendChild( + (new CommonMark\Node\Paragraph) + ->appendChild($text)); +-echo CommonMark\Render\XML($document); ++if (CommonMark\Render\XML($document)) { ++ echo "OK"; ++} + ?> + --EXPECT-- +- +- +- +- +- Hello World +- +- ++OK + diff --git a/php-pecl-cmark.spec b/php-pecl-cmark.spec index a4c7b6f..0479c5e 100644 --- a/php-pecl-cmark.spec +++ b/php-pecl-cmark.spec @@ -1,6 +1,6 @@ # remirepo spec file for php-pecl-cmark # -# Copyright (c) 2018 Remi Collet +# Copyright (c) 2018-2020 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -23,10 +23,12 @@ Summary: CommonMark extension Name: %{?sub_prefix}php-pecl-%{pecl_name} Version: 1.1.0 -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 4%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP -URL: http://pecl.php.net/package/%{pecl_name} -Source0: http://pecl.php.net/get/%{pecl_name}-%{version}.tgz +URL: https://pecl.php.net/package/%{pecl_name} +Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz + +Patch0: https://github.com/krakjoe/cmark/commit/68dc8c677e43e8431f8a109a289d3a4c5195e0f3.patch BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel >= 7 @@ -94,6 +96,8 @@ sed -e '/tests/s/role="test"/role="src"/'\ -i package.xml cd NTS +%patch0 -p1 -b .up0 + # Sanity check, really often broken extver=$(sed -n '/define PHP_CMARK_VERSION/{s/.* "//;s/".*$//;p}' php_cmark.h) if test "x${extver}" != "x%{version}%{?prever:-%{prever}}"; then @@ -223,6 +227,9 @@ fi %changelog +* Fri Feb 21 2020 Remi Collet - 1.1.0-4 +- add upstream patch for test suite + * Thu Aug 16 2018 Remi Collet - 1.1.0-3 - rebuild for 7.3.0beta2 new ABI -- cgit