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

Function two_files

atomic-repository/tests/it/remote_cache_parity_test.rs:195–214  ·  view source on GitHub ↗
(repo: &Repository)

Source from the content-addressed store, hash-verified

193}
194
195fn two_files(repo: &Repository) {
196 let root = repo.root().to_path_buf();
197 write(&root, "README.md", "hello\nworld\n");
198 write(&root, "src/lib.rs", "pub fn a() {}\npub fn b() {}\n");
199 repo.add(
200 repo.require_working_copy_id().unwrap(),
201 "README.md",
202 TrackingOptions::default(),
203 )
204 .unwrap();
205 repo.add(
206 repo.require_working_copy_id().unwrap(),
207 "src/lib.rs",
208 TrackingOptions::default(),
209 )
210 .unwrap();
211 record_and_apply(repo, "first");
212 write(&root, "README.md", "hello\nthere\nworld\n");
213 record_and_apply(repo, "second");
214}
215
216#[test]
217fn modifying_a_file() {

Calls 6

record_and_applyFunction · 0.85
writeFunction · 0.70
rootMethod · 0.45
unwrapMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected