MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_stats_merge

Function test_stats_merge

atomic-core/src/record/workflow/record/tests.rs:161–178  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

159
160#[test]
161fn test_stats_merge() {
162 let mut stats1 = RecordingStats::new();
163 stats1.files_recorded = 2;
164 stats1.hunks_created = 3;
165 stats1.lines_added = 10;
166
167 let mut stats2 = RecordingStats::new();
168 stats2.files_recorded = 1;
169 stats2.hunks_created = 2;
170 stats2.lines_deleted = 5;
171
172 stats1.merge(&stats2);
173
174 assert_eq!(stats1.files_recorded, 3);
175 assert_eq!(stats1.hunks_created, 5);
176 assert_eq!(stats1.lines_added, 10);
177 assert_eq!(stats1.lines_deleted, 5);
178}
179
180#[test]
181fn test_stats_clone() {

Callers

nothing calls this directly

Calls 1

mergeMethod · 0.45

Tested by

no test coverage detected