#6836·atlantis

ignorePlanFiles assumes Git always creates .git/info

Author: krewenkiCreated Sep 3, 2026Updated Sep 7, 2026

The ignorePlanFiles test helper writes directly to .git/info/exclude without creating the parent directory first.

That assumption doesn't hold with Git 2.55.0. A fresh clone here doesn't contain .git/info, so these tests fail during setup:

bash
go test ./server/events -run 'TestClone_ResetOnWrongCommit($|WithMergeStrategy$)' -count=1

Both fail with open .../.git/info/exclude: no such file or directory. We never reach the stale plan cleanup behavior the tests are meant to exercise.

This should probably just create filepath.Dir(excludePath) before writing the file. Small fix, but it keeps the test from depending on an incidental detail of the Git version that created the clone.