Skip to content

Commit

Permalink
[FAB-12440] run goimports on tree and re-enable
Browse files Browse the repository at this point in the history
Let the tool do what it wants with the imports.

Change-Id: I115230369be6349d89b5869951ce088ce38d8fb6
Signed-off-by: Matthew Sykes <sykesmat@us.ibm.com>
  • Loading branch information
sykesm committed Oct 17, 2018
1 parent 99ca3f8 commit cb5ee6b
Show file tree
Hide file tree
Showing 218 changed files with 225 additions and 470 deletions.
3 changes: 1 addition & 2 deletions bccsp/mocks/mocks.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,12 @@ limitations under the License.
package mocks

import (
"bytes"
"crypto"
"errors"
"hash"
"reflect"

"bytes"

"github.com/hyperledger/fabric/bccsp"
)

Expand Down
3 changes: 1 addition & 2 deletions bccsp/sw/aes_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,11 @@ import (
"bytes"
"crypto/aes"
"crypto/rand"
"io"
"math/big"
mrand "math/rand"
"testing"

"io"

"github.com/hyperledger/fabric/bccsp"
"github.com/hyperledger/fabric/bccsp/mocks"
"github.com/hyperledger/fabric/bccsp/utils"
Expand Down
3 changes: 1 addition & 2 deletions bccsp/sw/aeskey.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ limitations under the License.
package sw

import (
"errors"

"crypto/sha256"
"errors"

"github.com/hyperledger/fabric/bccsp"
)
Expand Down
9 changes: 3 additions & 6 deletions bccsp/sw/ecdsakey.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,11 @@ package sw

import (
"crypto/ecdsa"
"crypto/x509"
"fmt"

"crypto/elliptic"
"crypto/sha256"

"crypto/x509"
"errors"

"crypto/elliptic"
"fmt"

"github.com/hyperledger/fabric/bccsp"
)
Expand Down
12 changes: 5 additions & 7 deletions bccsp/sw/fileks.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,16 @@ package sw

import (
"bytes"
"io/ioutil"
"os"
"sync"

"errors"
"strings"

"crypto/ecdsa"
"crypto/rsa"
"encoding/hex"
"errors"
"fmt"
"io/ioutil"
"os"
"path/filepath"
"strings"
"sync"

"github.com/hyperledger/fabric/bccsp"
"github.com/hyperledger/fabric/bccsp/utils"
Expand Down
3 changes: 1 addition & 2 deletions bccsp/sw/fileks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,8 @@ import (
"path/filepath"
"testing"

"github.com/stretchr/testify/assert"

"github.com/hyperledger/fabric/bccsp/utils"
"github.com/stretchr/testify/assert"
)

func TestInvalidStoreKey(t *testing.T) {
Expand Down
3 changes: 1 addition & 2 deletions bccsp/sw/impl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,10 @@ import (
"math/big"
"net"
"os"
"reflect"
"testing"
"time"

"reflect"

"github.com/hyperledger/fabric/bccsp"
"github.com/hyperledger/fabric/bccsp/signer"
"github.com/hyperledger/fabric/bccsp/sw/mocks"
Expand Down
6 changes: 2 additions & 4 deletions bccsp/sw/keyderiv.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,11 @@ package sw

import (
"crypto/ecdsa"
"fmt"

"crypto/hmac"
"errors"
"fmt"
"math/big"

"crypto/hmac"

"github.com/hyperledger/fabric/bccsp"
)

Expand Down
5 changes: 2 additions & 3 deletions bccsp/sw/keyimport.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,11 @@ limitations under the License.
package sw

import (
"errors"
"fmt"

"crypto/ecdsa"
"crypto/rsa"
"crypto/x509"
"errors"
"fmt"
"reflect"

"github.com/hyperledger/fabric/bccsp"
Expand Down
9 changes: 3 additions & 6 deletions bccsp/sw/rsakey.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,11 @@ package sw

import (
"crypto/rsa"
"crypto/x509"
"fmt"

"crypto/sha256"

"errors"

"crypto/x509"
"encoding/asn1"
"errors"
"fmt"
"math/big"

"github.com/hyperledger/fabric/bccsp"
Expand Down
3 changes: 1 addition & 2 deletions bccsp/sw/sw_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ package sw

import (
"errors"
"testing"

"reflect"
"testing"

"github.com/hyperledger/fabric/bccsp"
"github.com/hyperledger/fabric/bccsp/mocks"
Expand Down
3 changes: 1 addition & 2 deletions cmd/common/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,10 @@ package common

import (
"fmt"
"io"
"os"
"path/filepath"

"io"

"github.com/hyperledger/fabric/cmd/common/comm"
"github.com/hyperledger/fabric/cmd/common/signer"
"gopkg.in/alecthomas/kingpin.v2"
Expand Down
5 changes: 2 additions & 3 deletions cmd/common/cli_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,10 @@ package common
import (
"bytes"
"fmt"
"path/filepath"
"testing"

"math/rand"
"os"
"path/filepath"
"testing"

"github.com/hyperledger/fabric/cmd/common/signer"
"github.com/pkg/errors"
Expand Down
1 change: 0 additions & 1 deletion common/capabilities/application_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"testing"

cb "github.com/hyperledger/fabric/protos/common"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/capabilities/capabilities.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ package capabilities
import (
"github.com/hyperledger/fabric/common/flogging"
cb "github.com/hyperledger/fabric/protos/common"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/capabilities/capabilities_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"testing"

cb "github.com/hyperledger/fabric/protos/common"

"github.com/stretchr/testify/assert"
)

Expand Down
3 changes: 1 addition & 2 deletions common/capabilities/channel_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,8 @@ package capabilities
import (
"testing"

cb "github.com/hyperledger/fabric/protos/common"

"github.com/hyperledger/fabric/msp"
cb "github.com/hyperledger/fabric/protos/common"
"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/capabilities/orderer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"testing"

cb "github.com/hyperledger/fabric/protos/common"

"github.com/stretchr/testify/assert"
)

Expand Down
5 changes: 2 additions & 3 deletions common/cauthdsl/cauthdsl_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,11 @@ limitations under the License.
package cauthdsl

import (
cb "github.com/hyperledger/fabric/protos/common"
"github.com/hyperledger/fabric/protos/msp"

"sort"

"github.com/golang/protobuf/proto"
cb "github.com/hyperledger/fabric/protos/common"
"github.com/hyperledger/fabric/protos/msp"
"github.com/hyperledger/fabric/protos/utils"
)

Expand Down
5 changes: 2 additions & 3 deletions common/cauthdsl/policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@ import (
"errors"
"fmt"

"github.com/hyperledger/fabric/common/policies"
cb "github.com/hyperledger/fabric/protos/common"

"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric/common/policies"
"github.com/hyperledger/fabric/msp"
cb "github.com/hyperledger/fabric/protos/common"
)

type provider struct {
Expand Down
3 changes: 1 addition & 2 deletions common/cauthdsl/policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ import (
"fmt"
"testing"

"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric/common/policies"
cb "github.com/hyperledger/fabric/protos/common"

"github.com/golang/protobuf/proto"
"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/acls_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"testing"

pb "github.com/hyperledger/fabric/protos/peer"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/application.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"github.com/hyperledger/fabric/common/capabilities"
cb "github.com/hyperledger/fabric/protos/common"
pb "github.com/hyperledger/fabric/protos/peer"

"github.com/pkg/errors"
)

Expand Down
3 changes: 1 addition & 2 deletions common/channelconfig/application_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,10 @@ package channelconfig
import (
"testing"

"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric/common/capabilities"
cb "github.com/hyperledger/fabric/protos/common"
"github.com/hyperledger/fabric/protos/utils"

"github.com/golang/protobuf/proto"
. "github.com/onsi/gomega"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/applicationorg.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import (

cb "github.com/hyperledger/fabric/protos/common"
pb "github.com/hyperledger/fabric/protos/peer"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/bundle.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import (
"github.com/hyperledger/fabric/msp"
cb "github.com/hyperledger/fabric/protos/common"
"github.com/hyperledger/fabric/protos/utils"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/bundle_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import (

cb "github.com/hyperledger/fabric/protos/common"
ab "github.com/hyperledger/fabric/protos/orderer"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import (
"github.com/hyperledger/fabric/common/util"
"github.com/hyperledger/fabric/msp"
cb "github.com/hyperledger/fabric/protos/common"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/channel_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import (
"github.com/hyperledger/fabric/bccsp"
"github.com/hyperledger/fabric/common/util"
cb "github.com/hyperledger/fabric/protos/common"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/consortium.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ package channelconfig

import (
cb "github.com/hyperledger/fabric/protos/common"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/consortiums_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import (
"testing"

cb "github.com/hyperledger/fabric/protos/common"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/orderer.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
"github.com/hyperledger/fabric/common/capabilities"
cb "github.com/hyperledger/fabric/protos/common"
ab "github.com/hyperledger/fabric/protos/orderer"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/orderer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"testing"

ab "github.com/hyperledger/fabric/protos/orderer"

"github.com/stretchr/testify/assert"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/organization.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
"github.com/hyperledger/fabric/msp"
cb "github.com/hyperledger/fabric/protos/common"
mspprotos "github.com/hyperledger/fabric/protos/msp"

"github.com/pkg/errors"
)

Expand Down
1 change: 0 additions & 1 deletion common/channelconfig/realconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import (
"github.com/hyperledger/fabric/common/tools/configtxgen/encoder"
genesisconfig "github.com/hyperledger/fabric/common/tools/configtxgen/localconfig"
"github.com/hyperledger/fabric/protos/utils"

"github.com/stretchr/testify/assert"
)

Expand Down
Loading

0 comments on commit cb5ee6b

Please sign in to comment.