Fix test `test_node_snapshot_encryption`
@@ -13,6 +13,9 @@ fn test_snapshot_encryption<T: Simulator>(cluster: &mut Cluster<T>) {
}
cluster.pd_client.must_add_peer(r1, new_learner_peer(2, 2));
+ cluster.pd_client.must_add_peer(r1, new_peer(2, 2));
+ // ensure that peer 2 has all previous logs.
+ cluster.must_put(b"00", b"00");
must_get_equal(&cluster.get_engine(2), b"key-00", b"value");
must_get_cf_equal(&cluster.get_engine(2), "lock", b"key-50", b"value");
must_get_cf_equal(&cluster.get_engine(2), "write", b"key-99", b"value");
