You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@zookeeper.apache.org by GitBox <gi...@apache.org> on 2019/08/30 20:34:12 UTC
[GitHub] [zookeeper] hanm commented on a change in pull request #1069:
ZOOKEEPER-3056: Fails to load database with missing snapshot file but with
valid transaction log file.
hanm commented on a change in pull request #1069: ZOOKEEPER-3056: Fails to load database with missing snapshot file but with valid transaction log file.
URL: https://github.com/apache/zookeeper/pull/1069#discussion_r319666491
##########
File path: zookeeper-server/src/test/java/org/apache/zookeeper/test/EmptiedSnapshotRecoveryTest.java
##########
@@ -119,7 +125,15 @@ public void testRestoreWithEmptySnapFiles() throws Exception {
*/
@Test
public void testRestoreWithNoSnapFiles() throws Exception {
- runTest(false);
+ runTest(false, false);
+ }
+
+ @Test
+ public void testRestoreWithTrustedEmptySnapFiles() throws Exception {
+ FileTxnSnapLog.setTrustEmptySnapshotFlag(true);
Review comment:
good catch, and find bug complains about something similar. I changed the flag variable to an instance variable instead and move the set / check logic inside the shared test implementation. Tests will not be interfering with each other.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services