def METHOD_NAME(in_git_dir):
    in_git_dir.join('foo/cfg.yaml').ensure()
    with in_git_dir.join('foo').as_cwd():
        args = _args(command='run', files=[], commit_msg_filename='t.txt')
        main._adjust_args_and_chdir(args)
        assert os.getcwd() == in_git_dir
        assert args.commit_msg_filename == os.path.join('foo', 't.txt')