You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: pgp_import_key_test.go
    path of file: ./repos/client/go/engine
    
    the code of the file until where you have to start completion: // Copyright 2015 Keybase, Inc. All rights reserved. Use of
// this source code is governed by the included BSD license.

package engine

import (
	"bytes"
	"testing"

	"github.com/keybase/client/go/libkb"
	keybase1 "github.com/keybase/client/go/protocol/keybase1"
	"github.com/stretchr/testify/require"
	"golang.org/x/net/context"

	"github.com/keybase/go-crypto/openpgp"
	"github.com/keybase/go-crypto/openpgp/armor"
)

// TestPGPSavePublicPush runs the PGPSave engine, pushing the
// public key to api server and checks that it runs without error.
func TestPGPImportAndExport(t *testing.T) {
	tc := SetupEngineTest(t, "pgpsave")
	defer tc.Cleanup()

	u := CreateAndSignupFakeUser(tc, "login")
	secui := &libkb.TestSecretUI{Passphrase: u.Passphrase}
	uis := libkb.UIs{LogUI: tc.G.UI.GetLogUI(), SecretUI: secui}

	// try all four permutations of push opt
    
func TestPGPImportLocalPrivateThenServer(t *testing.T) {
	tc := SetupEngineTest(t, "pgpsave")
	defer tc.Cleanup()

	user := CreateAndSignupFakeUser(tc, "login")
	secui := &libkb.TestSecretUI{Passphrase: user.Passphrase}
	uis := libkb.UIs{LogUI: tc.G.UI.GetLogUI(), SecretUI: secui}

	_, _, key := genPGPKeyAndArmor(t, tc, user.Email)

	// Import a private key locally first.
	eng, err := NewPGPKeyImportEngineFromBytes(tc.G, []byte(key), false /* pushSecret*/)
	require.NoError(t, err)
	mctx := NewMetaContextForTest(tc).WithUIs(uis)
	err = RunEngine2(mctx, eng)
	require.NoError(t, err)

	// Can we import locally twice?
	eng, err = NewPGPKeyImportEngineFromBytes(tc.G, []byte(key), false /* pushSecret*/)
	require.NoError(t, err)
	mctx = NewMetaContextForTest(tc).WithUIs(uis)
	err = RunEngine2(mctx, eng)
	require.NoError(t, err)

	kid := eng.GetKID()

	ss, err := mctx.ActiveDevice().SyncSecretsForce(mctx)
	require.NoError(t, err)
	_, ok := ss.FindPrivateKey(kid.String())
	require.False(t, ok)

	// Try to import with push secret afterwards - user also wants
	// to have this key available online.
	eng, err = NewPGPKeyImportEngineFromBytes(tc.G, []byte(key), true /* pushSecret*/)
	require.NoError(t, err)
	mctx = NewMetaContextForTest(tc).WithUIs(uis)
	err = RunEngine2(mctx, eng)
	require.NoError(t, err)

	ss, err = mctx.ActiveDevice().SyncSecretsForce(mctx)
	require.NoError(t, err)
	privKey, ok := ss.FindPrivateKey(kid.String())
	require.True(t, ok)
	require.NotEmpty(t, privKey.Bundle)
}