Skip to content

Commit 08887b2

Browse files
committed
[FAB-10545] extended peer runner for some e2e tests
added the option to pass env vars that are needed for private data e2e tests (leader election flags) and also added a function that allows to get channel info which will be used in some e2e tests. Change-Id: If2de895329f6aa53f7f47d945225fd31d4f1da5f Signed-off-by: nirro <nirro@il.ibm.com>
1 parent 8ba2baf commit 08887b2

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

integration/runner/peer.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,19 @@ func (p *Peer) CreateChannel(channel string, filename string, orderer string) *g
107107
return r
108108
}
109109

110+
func (p *Peer) GetChannelInfo(channel string) *ginkgomon.Runner {
111+
cmd := exec.Command(p.Path, "channel", "getinfo", "-c", channel)
112+
p.setupEnvironment(cmd)
113+
114+
r := ginkgomon.New(ginkgomon.Config{
115+
Name: "channel get info",
116+
AnsiColorCode: "4;35m",
117+
Command: cmd,
118+
})
119+
120+
return r
121+
}
122+
110123
func (p *Peer) FetchChannel(channel string, filename string, block string, orderer string) *ginkgomon.Runner {
111124
cmd := exec.Command(p.Path, "channel", "fetch", block, "-c", channel, "-o", orderer, filename)
112125
p.setupEnvironment(cmd)

0 commit comments

Comments
 (0)