func (a *MockAction) ExecuteTx(chaincodeID, fctn string, args [][]byte) error {
	_, err := a.Invoker(chaincodeID, fctn, args)
	return err
}
ExecuteTx executes a transaction on the given chaincode with the given function and args
package action
import (
	"fmt"
	"github.com/hyperledger/fabric-sdk-go/pkg/client/channel"
	"github.com/hyperledger/fabric-sdk-go/pkg/common/logging"
	fabApi "github.com/hyperledger/fabric-sdk-go/pkg/common/providers/fab"
	"github.com/hyperledger/fabric-sdk-go/pkg/fab/mocks"
	"github.com/hyperledger/fabric-sdk-go/pkg/fab/peer"
	"github.com/pkg/errors"
	"github.com/securekey/fabric-snaps/configurationsnap/cmd/configcli/cliconfig"
	"github.com/spf13/pflag"
)
type MockInvoker func(chaincodeID, fctn string, args [][]byte) ([]byte, error)
type MockAction struct {
	action
	Invoker  MockInvoker
	Response []byte
}
func (a *MockAction) Initialize() error {
	if err := cliconfig.InitConfig(); err != nil {
		return err
	}
	logging.SetLevel("", levelFromName(cliconfig.Config().LoggingLevel()))
	channelID := cliconfig.Config().ChannelID()
	if channelID == "" {
		return errors.New("no channel ID specified")
	}
	return a.initTargetPeers()
}
func (a *MockAction) ChannelClient() (*channel.Client, error) {
	panic("not implemented")
}
func (a *MockAction) Query(chaincodeID, fctn string, args [][]byte) ([]byte, error) {
	return a.Invoker(chaincodeID, fctn, args)
}