Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(513)

Unified Diff: logdog/client/butlerlib/streamclient/stream_test.go

Issue 2456953003: LogDog: Update client/bootstrap to generate URLs. (Closed)
Patch Set: Winders Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « logdog/client/butlerlib/streamclient/stream.go ('k') | logdog/client/butlerlib/streamproto/properties.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: logdog/client/butlerlib/streamclient/stream_test.go
diff --git a/logdog/client/butlerlib/streamclient/stream_test.go b/logdog/client/butlerlib/streamclient/stream_test.go
index 8544cebc2c3eb1efce989eaed5fe1d1a7a9707f5..b210b463326bb334410a446cd437d4b2987cf900 100644
--- a/logdog/client/butlerlib/streamclient/stream_test.go
+++ b/logdog/client/butlerlib/streamclient/stream_test.go
@@ -18,12 +18,13 @@ import (
func TestStreamImpl(t *testing.T) {
Convey(`A stream writing to a buffer`, t, func() {
buf := bytes.Buffer{}
- si := &streamImpl{
- Properties: &streamproto.Properties{},
+ si := streamImpl{
WriteCloser: &nopWriteCloser{Writer: &buf},
+ props: (&streamproto.Flags{}).Properties(),
}
+
Convey(`TEXT`, func() {
- si.Properties.StreamType = logpb.StreamType_TEXT
+ si.props.StreamType = logpb.StreamType_TEXT
Convey(`Will error if WriteDatagram is called.`, func() {
So(si.WriteDatagram([]byte(nil)), ShouldNotBeNil)
@@ -38,7 +39,7 @@ func TestStreamImpl(t *testing.T) {
})
Convey(`DATAGRAM`, func() {
- si.Properties.StreamType = logpb.StreamType_DATAGRAM
+ si.props.StreamType = logpb.StreamType_DATAGRAM
Convey(`Will error if Write is called.`, func() {
_, err := si.Write([]byte(nil))
« no previous file with comments | « logdog/client/butlerlib/streamclient/stream.go ('k') | logdog/client/butlerlib/streamproto/properties.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698