Skip to content

Commit

Permalink
Merge "Minor cleanup for orderer without a system channel"
Browse files Browse the repository at this point in the history
  • Loading branch information
denyeart authored and Gerrit Code Review committed Nov 20, 2019
2 parents 8aca8e7 + cc39bc7 commit 3adcab3
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
4 changes: 1 addition & 3 deletions integration/e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -316,8 +316,6 @@ var _ = Describe("EndToEnd", func() {
var ordererProcess ifrit.Process
BeforeEach(func() {
soloConfig := nwo.BasicSolo()
soloConfig.RemovePeer("Org1", "peer1")
soloConfig.RemovePeer("Org2", "peer1")
network = nwo.New(soloConfig, testDir, client, StartPort(), components)
network.GenerateConfigTree()

Expand All @@ -330,7 +328,7 @@ var _ = Describe("EndToEnd", func() {
ordererRunner := network.OrdererRunner(orderer)
ordererProcess = ifrit.Invoke(ordererRunner)
Eventually(ordererProcess.Ready, network.EventuallyTimeout).Should(BeClosed())
Eventually(ordererRunner.Err(), network.EventuallyTimeout).Should(gbytes.Say("registrar initializing with no system channel"))
Eventually(ordererRunner.Err(), network.EventuallyTimeout).Should(gbytes.Say("registrar initializing without a system channel"))
})

AfterEach(func() {
Expand Down
2 changes: 1 addition & 1 deletion orderer/common/multichannel/registrar.go
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ func (r *Registrar) Initialize(consenters map[string]consensus.Consenter) {
}

if r.systemChannelID == "" {
logger.Info("registrar initializing with no system channel")
logger.Warning("registrar initializing without a system channel")
}
}

Expand Down
4 changes: 2 additions & 2 deletions orderer/common/server/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ func TestInitializeMultichannelRegistrar(t *testing.T) {

signer := &server_mocks.SignerSerializer{}

t.Run("registrar with system channel", func(t *testing.T) {
t.Run("registrar with a system channel", func(t *testing.T) {
lf, _, err := createLedgerFactory(conf, &disabled.Provider{})
assert.NoError(t, err)
bootBlock := file.New(genesisFile).GenesisBlock()
Expand All @@ -405,7 +405,7 @@ func TestInitializeMultichannelRegistrar(t *testing.T) {
assert.Equal(t, "testchannelid", registrar.SystemChannelID())
})

t.Run("registrar with no system channel", func(t *testing.T) {
t.Run("registrar without a system channel", func(t *testing.T) {
conf.General.GenesisMethod = "none"
conf.General.GenesisFile = ""
lf, _, err := createLedgerFactory(conf, &disabled.Provider{})
Expand Down

0 comments on commit 3adcab3

Please sign in to comment.