diff --git a/lib/testutils/src/lib.rs b/lib/testutils/src/lib.rs index ae74b427ea..d2966a5417 100644 --- a/lib/testutils/src/lib.rs +++ b/lib/testutils/src/lib.rs @@ -531,6 +531,8 @@ pub fn assert_rebased_onto( new_commit } +/// Maps children of an abandoned commit to a new rebase target. +/// /// If `expected_old_commit` was abandoned, the `rebased` map indicates the /// commit the children of `expected_old_commit` should be rebased to, which /// would have a different change id. This happens when the EmptyBehavior in diff --git a/lib/testutils/src/test_backend.rs b/lib/testutils/src/test_backend.rs index c4e9ac115f..1630cb4db6 100644 --- a/lib/testutils/src/test_backend.rs +++ b/lib/testutils/src/test_backend.rs @@ -78,11 +78,14 @@ fn get_hash(content: &(impl jj_lib::content_hash::ContentHash + ?Sized)) -> Vec< jj_lib::content_hash::blake2b_hash(content).as_slice()[..HASH_LENGTH].to_vec() } -/// A commit backend for use in tests. It's meant to be strict, in order to -/// catch bugs where we make the wrong assumptions. For example, unlike both -/// `GitBackend` and `LocalBackend`, this backend doesn't share objects written -/// to different paths (writing a file with contents X to path A will not make -/// it possible to read that contents from path B given the same `FileId`). +/// A commit backend for use in tests. +/// +/// It's meant to be strict, in order to catch bugs where we make the +/// wrong assumptions. For example, unlike both `GitBackend` and +/// `LocalBackend`, this backend doesn't share objects written to +/// different paths (writing a file with contents X to path A will not +/// make it possible to read that contents from path B given the same +/// `FileId`). pub struct TestBackend { root_commit_id: CommitId, root_change_id: ChangeId,