You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
configUpdateEnvelopePath:=update.Flag("config-update-envelope", "Path to the file containing an up-to-date config update envelope for the channel").Short('e').Required().String()
64
+
tlsHandshakeTimeShift:=update.Flag("tlsHandshakeTimeShift", "The amount of time to shift backwards for certificate expiration checks during TLS handshakes with the orderer endpoint").Short('t').Default("0").Duration()
It("returns with exit code 1 and prints the error", func() {
574
+
args:= []string{
575
+
"channel",
576
+
"update",
577
+
"--orderer-address", ordererURL,
578
+
"--channelID", channelID,
579
+
"--config-update-envelope", envelopePath,
580
+
"--ca-file", ordererCACert,
581
+
"--client-cert", clientCert,
582
+
"--client-key", clientKey,
583
+
}
584
+
output, exit, err:=executeForArgs(args)
585
+
586
+
checkFlagError(output, exit, err, "failed to retrieve channel id - payload header is empty")
587
+
})
588
+
})
589
+
590
+
Context("when the --channelID does not match the channel ID in the envelope", func() {
591
+
BeforeEach(func() {
592
+
channelID="not-the-channel-youre-looking-for"
593
+
})
594
+
595
+
It("returns with exit code 1 and prints the error", func() {
596
+
args:= []string{
597
+
"channel",
598
+
"update",
599
+
"--orderer-address", ordererURL,
600
+
"--channelID", channelID,
601
+
"--config-update-envelope", envelopePath,
602
+
"--ca-file", ordererCACert,
603
+
"--client-cert", clientCert,
604
+
"--client-key", clientKey,
605
+
}
606
+
output, exit, err:=executeForArgs(args)
607
+
608
+
checkFlagError(output, exit, err, "specified --channelID not-the-channel-youre-looking-for does not match channel ID testing123 in config update envelope")
609
+
})
610
+
})
611
+
612
+
Context("when the envelope isn't a valid config update", func() {
Status 201 and the channel details are returned indicating that the channel has been
281
+
successfully updated.
282
+
223
283
<arel="license"href="http://creativecommons.org/licenses/by/4.0/"><imgalt="Creative Commons License"style="border-width:0"src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br />This work is licensed under a <arel="license"href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.
Status 201 and the channel details are returned indicating that the channel has been
110
+
successfully updated.
111
+
86
112
<arel="license"href="http://creativecommons.org/licenses/by/4.0/"><imgalt="Creative Commons License"style="border-width:0"src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br />This work is licensed under a <arel="license"href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.
0 commit comments