| 22 | |
| 23 | impl Fixture { |
| 24 | fn colocated() -> Self { |
| 25 | let fixture = Self::no_git(); |
| 26 | fixture.git_ok(&["init", "-q"]); |
| 27 | fixture.git_ok(&["symbolic-ref", "HEAD", "refs/heads/main"]); |
| 28 | fixture.git_ok(&["config", "user.name", "Atomic Test"]); |
| 29 | fixture.git_ok(&["config", "user.email", "atomic@example.com"]); |
| 30 | fixture.git_ok(&["config", "core.autocrlf", "false"]); |
| 31 | fixture.git_ok(&["config", "commit.gpgsign", "false"]); |
| 32 | fs::write(fixture.root().join("tracked.txt"), b"checkpoint\n") |
| 33 | .expect("write initial tracked file"); |
| 34 | fixture.git_ok(&["add", "tracked.txt"]); |
| 35 | fixture.git_ok(&["commit", "--no-gpg-sign", "-q", "-m", "checkpoint"]); |
| 36 | fixture.atomic_ok(&["git", "import", "--no-vault"]); |
| 37 | fixture.atomic_ok(&["git", "shim", "reconcile"]); |
| 38 | assert!( |
| 39 | fixture |
| 40 | .root() |
| 41 | .join(".atomic/bridge/workspace.json") |
| 42 | .is_file(), |
| 43 | "Git reconciliation must establish a valid shim checkpoint" |
| 44 | ); |
| 45 | fixture |
| 46 | } |
| 47 | |
| 48 | fn no_git() -> Self { |
| 49 | Self { |