changeset 49092:d200ecb76c72

rust-revlog: change default version from 2 to 1 in test builder Version 1 is the only version we support, so it seems like the natural choice for making it easy to create valid revlogs. Differential Revision: https://phab.mercurial-scm.org/D12563
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 15 Apr 2022 17:06:10 -0700
parents 9b5334c1e499
children 2a9a55ffe24f
files rust/hg-core/src/revlog/index.rs
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/rust/hg-core/src/revlog/index.rs	Fri Apr 15 09:39:27 2022 -0700
+++ b/rust/hg-core/src/revlog/index.rs	Fri Apr 15 17:06:10 2022 -0700
@@ -323,7 +323,7 @@
                 is_first: false,
                 is_inline: false,
                 is_general_delta: true,
-                version: 2,
+                version: 1,
                 offset: 0,
                 compressed_len: 0,
                 uncompressed_len: 0,
@@ -517,10 +517,10 @@
     fn version_test() {
         let bytes = IndexEntryBuilder::new()
             .is_first(true)
-            .with_version(1)
+            .with_version(2)
             .build();
 
-        assert_eq!(get_version(&bytes), 1)
+        assert_eq!(get_version(&bytes), 2)
     }
 }