Skip to content

Commit

Permalink
[FAB-6358] Expose packages in e2e tests
Browse files Browse the repository at this point in the history
Change-Id: I10bd8fda57e6eedaef3795ba6e578d26eda0ae80
Signed-off-by: Troy Ronda <troy@troyronda.com>
  • Loading branch information
troyronda committed Sep 30, 2017
1 parent 2fb9484 commit fc03fd7
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 35 deletions.
2 changes: 1 addition & 1 deletion pkg/fabric-client/channel/txnsender_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
fab "github.com/hyperledger/fabric-sdk-go/api/apifabclient"
"github.com/hyperledger/fabric-sdk-go/api/apitxn"
"github.com/hyperledger/fabric-sdk-go/api/apitxn/mocks"
"github.com/hyperledger/fabric-sdk-go/internal/github.com/hyperledger/fabric/common/cauthdsl"
"github.com/hyperledger/fabric-sdk-go/pkg/fabric-client/mocks"
"github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/common/cauthdsl"
"github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/protos/common"
pb "github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/protos/peer"
)
Expand Down
2 changes: 0 additions & 2 deletions scripts/third_party_pins/fabric/apply_fabric_client_utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ declare -a PKGS=(
"common/util"
"common/metadata"
"common/channelconfig"
"common/cauthdsl"
"common/ledger/util"

"common/logbridge"
Expand All @@ -44,7 +43,6 @@ declare -a FILES=(
"common/util/utils.go"
"common/metadata/metadata.go"
"common/channelconfig/keys.go"
"common/cauthdsl/cauthdsl_builder.go"

"common/logbridge/logbridge.go"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ IMPORT_SUBSTS=($IMPORT_SUBSTS)
GOIMPORTS_CMD=goimports

declare -a PKGS=(
"common/cauthdsl"
)

declare -a FILES=(
"common/cauthdsl/cauthdsl_builder.go"
)

echo 'Removing current upstream project from working directory ...'
rm -Rf "${INTERNAL_PATH}/common/flogging"
mkdir -p "${INTERNAL_PATH}/common/flogging"
rm -Rf "${INTERNAL_PATH}/common"
mkdir -p "${INTERNAL_PATH}/common"

# Create directory structure for packages
for i in "${PKGS[@]}"
Expand Down
3 changes: 3 additions & 0 deletions scripts/third_party_pins/fabric/apply_upstream.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ declare -a CLIENT_UTILS_IMPORT_SUBSTS=(
's/\"github.com\/hyperledger\/fabric\/common\/flogging/flogging\"github.com\/hyperledger\/fabric-sdk-go\/internal\/github.com\/hyperledger\/fabric\/common\/logbridge/g'
's/\"github.com\/op\/go-logging/logging\"github.com\/hyperledger\/fabric-sdk-go\/internal\/github.com\/hyperledger\/fabric\/common\/logbridge/g'
's/\"github.com\/hyperledger\/fabric\/bccsp/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/bccsp/g'
's/\"github.com\/hyperledger\/fabric\/common\/cauthdsl/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/common\/cauthdsl/g'
's/\"github.com\/hyperledger\/fabric\/protos\/common/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/protos\/common/g'
's/\"github.com\/hyperledger\/fabric\/protos\/peer/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/protos\/peer/g'
's/\"github.com\/hyperledger\/fabric\/protos\/msp/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/protos\/msp/g'
Expand All @@ -62,6 +63,8 @@ eval "INTERNAL_PATH=$THIRDPARTY_INTERNAL_FABRIC_PATH TMP_PROJECT_PATH=$TMP_PROJE
# external utils
echo "Pinning and patching fabric external utils ..."
declare -a EXTERNAL_UTILS_IMPORT_SUBSTS=(
's/\"github.com\/hyperledger\/fabric\/protos\/common/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/protos\/common/g'
's/\"github.com\/hyperledger\/fabric\/protos\/msp/\"github.com\/hyperledger\/fabric-sdk-go\/third_party\/github.com\/hyperledger\/fabric\/protos\/msp/g'
's/\"github.com\/hyperledger\/fabric\//\"github.com\/hyperledger\/fabric-sdk-go\/internal\/github.com\/hyperledger\/fabric\//g'
)
eval "INTERNAL_PATH=$THIRDPARTY_FABRIC_PATH TMP_PROJECT_PATH=$TMP_PROJECT_PATH IMPORT_SUBSTS=\"${EXTERNAL_UTILS_IMPORT_SUBSTS[*]}\" $SCRIPTS_PATH/apply_fabric_external_utils.sh"
Expand Down

This file was deleted.

2 changes: 1 addition & 1 deletion test/integration/base_test_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ import (
"github.com/hyperledger/fabric-sdk-go/api/apitxn"
deffab "github.com/hyperledger/fabric-sdk-go/def/fabapi"
"github.com/hyperledger/fabric-sdk-go/def/fabapi/opt"
"github.com/hyperledger/fabric-sdk-go/internal/github.com/hyperledger/fabric/common/cauthdsl"
"github.com/hyperledger/fabric-sdk-go/pkg/config"
"github.com/hyperledger/fabric-sdk-go/pkg/fabric-client/events"
"github.com/hyperledger/fabric-sdk-go/pkg/fabric-client/orderer"
fabricTxn "github.com/hyperledger/fabric-sdk-go/pkg/fabric-txn"
admin "github.com/hyperledger/fabric-sdk-go/pkg/fabric-txn/admin"
"github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/common/cauthdsl"
pb "github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/protos/peer"
)

Expand Down
2 changes: 1 addition & 1 deletion test/integration/orgs/test_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import (

deffab "github.com/hyperledger/fabric-sdk-go/def/fabapi"
"github.com/hyperledger/fabric-sdk-go/def/fabapi/opt"
"github.com/hyperledger/fabric-sdk-go/internal/github.com/hyperledger/fabric/common/cauthdsl"
"github.com/hyperledger/fabric-sdk-go/pkg/config"
client "github.com/hyperledger/fabric-sdk-go/pkg/fabric-client"
"github.com/hyperledger/fabric-sdk-go/pkg/fabric-client/channel"
Expand All @@ -29,6 +28,7 @@ import (
"github.com/hyperledger/fabric-sdk-go/pkg/fabric-txn/admin"
"github.com/hyperledger/fabric-sdk-go/test/integration"
"github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/bccsp/factory"
"github.com/hyperledger/fabric-sdk-go/third_party/github.com/hyperledger/fabric/common/cauthdsl"
)

var org1 = "Org1"
Expand Down

0 comments on commit fc03fd7

Please sign in to comment.