func (e *Environment) MustOpenAnother(tb testing.TB, openOpts ...func(*repo.Options)) repo.RepositoryWriter {
	tb.Helper()

	ctx := testlogging.Context(tb)

	rep2, err := repo.Open(ctx, e.ConfigFile(), e.Password, repoOptions(openOpts))
	if err != nil {
		tb.Fatalf("err: %v", err)
	}

	tb.Cleanup(func() {
		rep2.Close(ctx)
	})

	_, w, err := rep2.NewWriter(ctx, repo.WriteSessionOptions{Purpose: "test"})
	if err != nil {
		tb.Fatal(err)
	}

	return w
}
// MustOpenAnother opens another repository backed by the same storage location.
MustOpenAnother opens another repository backed by the same storage location.
// MustOpenAnother opens another repository backed by the same storage location .
func (e *Environment) MustOpenAnother(tb testing.TB, openOpts ...func(*repo.Options)) repo.RepositoryWriter {
	tb.Helper()
	ctx := testlogging.Context(tb)
	rep2, err := repo.Open(ctx, e.ConfigFile(), e.Password, repoOptions(openOpts))
	if err != nil {
		tb.Fatalf("err: %v", err)
	}
	tb.Cleanup(func() {
		rep2.Close(ctx)
	})
	_, w, err := rep2.NewWriter(ctx, repo.WriteSessionOptions{Purpose: "test"})
	if err != nil {
		tb.Fatal(err)
	}
	return w
}
func ( e * Environment ) MustOpenAnother ( tb testing . TB , openOpts ... func ( * repo . Options ) ) repo . RepositoryWriter { tb . Helper ( ) ctx := testlogging . Context ( tb ) rep2 , err := repo . Open ( ctx , e . ConfigFile ( ) , e . Password , repoOptions ( openOpts ) ) if err != nil { tb . Fatalf ( " " , err ) } tb . Cleanup ( func ( ) { rep2 . Close ( ctx ) } ) _ , w , err := rep2 . NewWriter ( ctx , repo . WriteSessionOptions { Purpose : " " } ) if err != nil { tb . Fatal ( err ) } return w }
MustOpenAnother opens another repository backed by the same storage location.
MustOpenAnother opens another repository backed by the same storage location .