it might happen that it is alredy saving, so make sure that test won't fail because of this

This commit is contained in:
Jonathan Leibiusky
2013-09-03 14:05:50 -03:00
parent ad001d1a72
commit 2ed1f073ff

View File

@@ -12,8 +12,13 @@ import redis.clients.jedis.exceptions.JedisDataException;
public class ControlCommandsTest extends JedisCommandTestBase {
@Test
public void save() {
try {
String status = jedis.save();
assertEquals("OK", status);
} catch (JedisDataException e) {
assertTrue("ERR Background save already in progress"
.equalsIgnoreCase(e.getMessage()));
}
}
@Test