Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
radicle/identity: Stabilize tests
✗ CI failure Lorenz Leutgeb committed 6 months ago
commit 3780f908a28f5f715a7c090293db53d45ad3cdc0
parent 60798cdbc3960e25358fc31c4a7451df78d38968
2 failed (2 total) View logs
1 file changed +12 -4
modified crates/radicle/src/cob/identity.rs
@@ -1323,12 +1323,16 @@ mod test {
            .unwrap();

        bob.repo.fetch(alice);
-
        let a3 = alice_identity.redact(a2, &alice.signer).unwrap();
+
        let a3 = cob::git::stable::with_advanced_timestamp(|| {
+
            alice_identity.redact(a2, &alice.signer).unwrap()
+
        });
        assert!(alice_identity.revision(&a1).is_some());
        assert_eq!(alice_identity.timeline, vec![a0, a1, a2, a3]);

        let mut bob_identity = Identity::load_mut(&*bob.repo).unwrap();
-
        let b1 = bob_identity.accept(&a2, &bob.signer).unwrap();
+
        let b1 = cob::git::stable::with_advanced_timestamp(|| {
+
            bob_identity.accept(&a2, &bob.signer).unwrap()
+
        });

        assert_eq!(bob_identity.timeline, vec![a0, a1, a2, b1]);
        assert_eq!(bob_identity.revision(&a2).unwrap().state, State::Accepted);
@@ -1454,11 +1458,15 @@ mod test {

        // Bob accepts alice's revision.
        let mut bob_identity = Identity::load_mut(&*bob.repo).unwrap();
-
        let b1 = bob_identity.accept(&a2, &bob.signer).unwrap();
+
        let b1 = cob::git::stable::with_advanced_timestamp(|| {
+
            bob_identity.accept(&a2, &bob.signer).unwrap()
+
        });

        // Eve rejects the revision, not knowing.
        let mut eve_identity = Identity::load_mut(&*eve.repo).unwrap();
-
        let e1 = eve_identity.reject(a2, &eve.signer).unwrap();
+
        let e1 = cob::git::stable::with_advanced_timestamp(|| {
+
            eve_identity.reject(a2, &eve.signer).unwrap()
+
        });
        assert!(eve_identity.revision(&a2).unwrap().is_active());

        // Then she submits a new revision.