From 592f9bd80e27e48f8159a90d6df055f8f0791f93 Mon Sep 17 00:00:00 2001 From: mattab <matthieu.aubry@gmail.com> Date: Thu, 1 Dec 2016 11:49:01 +1300 Subject: [PATCH] Make the CURL error message detected across CURL versions / OS --- tests/PHPUnit/Integration/HttpTest.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/PHPUnit/Integration/HttpTest.php b/tests/PHPUnit/Integration/HttpTest.php index e0eb78043d..823b6037be 100644 --- a/tests/PHPUnit/Integration/HttpTest.php +++ b/tests/PHPUnit/Integration/HttpTest.php @@ -230,8 +230,12 @@ class HttpTest extends \PHPUnit_Framework_TestCase } /** + * erroe message can be: + * curl_exec: server certificate verification failed. CAfile: /home/travis/build/piwik/piwik/core/DataFiles/cacert.pem CRLfile: none. Hostname requested was: self-signed.badssl.com + * or + * curl_exec: SSL certificate problem: self signed certificate. Hostname requested was: self-signed.badssl.com * @expectedException \Exception - * @expectedExceptionMessage curl_exec: SSL + * @expectedExceptionMessageRegExp /curl_exec: .*certificate.* / */ public function testCurlHttpsFailsWithInvalidCertificate() { -- GitLab