From 54c8a1ee9b5cfecb10006ba8e552f39e7b8ef754 Mon Sep 17 00:00:00 2001 From: Daniele Alessandri Date: Tue, 21 Oct 2014 11:16:55 +0200 Subject: [PATCH] [tests] Relax checks on invalid expire time messages. Previously there was a bug in Redis that returned the wrong command in -ERR messages when passing an invalid expire time with SETEX and PSETEX. Now that the bug has been fixed and that travis-ci uses a an updated version of Redis, our test suite turned red. --- tests/Predis/Command/StringPreciseSetExpireTest.php | 6 ++---- tests/Predis/Command/StringSetExpireTest.php | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/tests/Predis/Command/StringPreciseSetExpireTest.php b/tests/Predis/Command/StringPreciseSetExpireTest.php index 77df02cb..c93744e6 100644 --- a/tests/Predis/Command/StringPreciseSetExpireTest.php +++ b/tests/Predis/Command/StringPreciseSetExpireTest.php @@ -93,8 +93,7 @@ class StringPreciseSetExpireTest extends PredisCommandTestCase /** * @group connected * @expectedException \Predis\Response\ServerException - * @expectedExceptionMessage ERR invalid expire time in SETEX - * @todo Should not Redis return PSETEX instead of SETEX here? + * @expectedExceptionMessage ERR invalid expire time */ public function testThrowsExceptionOnZeroTTL() { @@ -104,8 +103,7 @@ class StringPreciseSetExpireTest extends PredisCommandTestCase /** * @group connected * @expectedException \Predis\Response\ServerException - * @expectedExceptionMessage ERR invalid expire time in SETEX - * @todo Should not Redis return PSETEX instead of SETEX here? + * @expectedExceptionMessage ERR invalid expire time */ public function testThrowsExceptionOnNegativeTTL() { diff --git a/tests/Predis/Command/StringSetExpireTest.php b/tests/Predis/Command/StringSetExpireTest.php index 59ff77bf..b52e9fab 100644 --- a/tests/Predis/Command/StringSetExpireTest.php +++ b/tests/Predis/Command/StringSetExpireTest.php @@ -94,7 +94,7 @@ class StringSetExpireTest extends PredisCommandTestCase /** * @group connected * @expectedException \Predis\Response\ServerException - * @expectedExceptionMessage ERR invalid expire time in SETEX + * @expectedExceptionMessage ERR invalid expire time */ public function testThrowsExceptionOnZeroTTL() { @@ -104,7 +104,7 @@ class StringSetExpireTest extends PredisCommandTestCase /** * @group connected * @expectedException \Predis\Response\ServerException - * @expectedExceptionMessage ERR invalid expire time in SETEX + * @expectedExceptionMessage ERR invalid expire time */ public function testThrowsExceptionOnNegativeTTL() {