func AppInstallationAuth(authClient []requests.Option) requests.Option {
	return octo.WithAppInstallationAuth(AppInstallationID, authClient, nil)
}
AppInstallationAuth returns auth
package testutil
import (
	"encoding/base64"
	"fmt"
	"io/ioutil"
	"net/http"
	"os"
	"path/filepath"
	"runtime"
	"strings"
	"testing"
	"github.com/dnaeon/go-vcr/cassette"
	"github.com/dnaeon/go-vcr/recorder"
	"github.com/joho/godotenv"
	"github.com/stretchr/testify/assert"
	"github.com/stretchr/testify/require"
	"github.com/willabides/octo-go"
	"github.com/willabides/octo-go/requests"
)
const (
	AppID int64 = 67080
	AppInstallationID int64 = 9437013
)
func init() {
	root, err := projectRoot()
	if err != nil {
		panic(err)
	}
	err = godotenv.Load(filepath.Join(root, ".env"))
	if err != nil {
		fmt.Println("no .env file. tests can still run")
	}
}
func appPrivateKey(t *testing.T) []byte {
	t.Helper()
	if os.Getenv("APP_PRIVATE_KEY") == "" {
		return nil
	}
	got, err := base64.StdEncoding.DecodeString(os.Getenv("APP_PRIVATE_KEY"))
	require.NoError(t, err)
	return got
}
func projectRoot() (string, error) {
	_, filename, _, _ := runtime.Caller(0)
	root := filepath.Dir(filepath.Dir(filepath.Dir(filename)))
	if filepath.Base(root) != "octo-go" {
		return "", fmt.Errorf("%s isn't octo-go", root)
	}
	return filepath.Abs(root)
}
func ProjectRoot(t *testing.T) string {
	t.Helper()
	got, err := projectRoot()
	assert.NoError(t, err)
	return got
}
func PATAuth() requests.Option {
	return octo.WithPATAuth(os.Getenv("GITHUB_TOKEN"))
}
func AppAuth(t *testing.T) requests.Option {
	key := appPrivateKey(t)
	if key == nil {
		return nil
	}
	return octo.WithAppAuth(AppID, key)
}