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

Method fresh_git_init

atomic-cli/tests/it/git_shim_opt_in_test.rs:29–41  ·  view source on GitHub ↗

`git init` (unborn HEAD, no commits) + `atomic init`: the reported "start both from scratch" sequence.

()

Source from the content-addressed store, hash-verified

27 /// `git init` (unborn HEAD, no commits) + `atomic init`: the reported
28 /// "start both from scratch" sequence.
29 fn fresh_git_init() -> Self {
30 let fixture = Self {
31 repository: TempDir::new().expect("repository tempdir"),
32 home: TempDir::new().expect("home tempdir"),
33 };
34 fixture.git_ok(&["init", "-q", "-b", "main"]);
35 fixture.git_ok(&["config", "user.name", "Opt-in Tests"]);
36 fixture.git_ok(&["config", "user.email", "opt-in@example.com"]);
37 fixture.git_ok(&["config", "commit.gpgsign", "false"]);
38 fixture.git_ok(&["config", "core.autocrlf", "false"]);
39 fixture.atomic_ok(&["init", "--no-vault", "--view", "main"]);
40 fixture
41 }
42
43 /// An existing Git repository with one commit, then `atomic init`.
44 fn existing_git_history() -> Self {

Callers

nothing calls this directly

Calls 2

git_okMethod · 0.45
atomic_okMethod · 0.45

Tested by

no test coverage detected