Skip to content

Commit 5dc2c7e

Browse files
committedOct 21, 2015
add sharness test for streaming output from daemon
License: MIT Signed-off-by: Jeromy <jeromyj@gmail.com>
1 parent 4470826 commit 5dc2c7e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
 

‎test/sharness/t0060-daemon.sh

+11
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,17 @@ test_expect_success "transport should be encrypted" '
109109
test_fsh cat swarmnc
110110
'
111111

112+
test_expect_success "output from streaming commands works" '
113+
test_expect_code 28 curl -m 2 http://localhost:5001/api/v0/stats/bw\?poll=true > statsout
114+
'
115+
116+
test_expect_success "output looks good" '
117+
grep TotalIn statsout > /dev/null &&
118+
grep TotalOut statsout > /dev/null &&
119+
grep RateIn statsout > /dev/null &&
120+
grep RateOut statsout >/dev/null
121+
'
122+
112123
# end same as in t0010
113124

114125
test_expect_success "daemon is still running" '

0 commit comments

Comments
 (0)
Please sign in to comment.