Преглед на файлове

[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.
Daniele Alessandri преди 10 години
родител
ревизия
d09c4f32f3
променени са 2 файла, в които са добавени 4 реда и са изтрити 6 реда
  1. 2 4
      tests/Predis/Command/StringPreciseSetExpireTest.php
  2. 2 2
      tests/Predis/Command/StringSetExpireTest.php

+ 2 - 4
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()
     {

+ 2 - 2
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()
     {