Update host test to add carriage return char

This commit is contained in:
Oliver Graff 2017-06-13 22:33:31 -07:00
parent ac76309ed8
commit acbfe51d9f

View File

@ -71,7 +71,7 @@ func TestHostNameCollision(t *testing.T) {
// Consume the initial buffer
scanner.Scan()
actual := stripPrompt(scanner.Text())
expected := " * foo joined. (Connected: 1)"
expected := " * foo joined. (Connected: 1)\r"
if actual != expected {
t.Errorf("Got %q; expected %q", actual, expected)
}
@ -87,7 +87,7 @@ func TestHostNameCollision(t *testing.T) {
t.Errorf("First client failed to get 'foo' name: %q", actual)
}
actual = stripPrompt(actual)
expected = " * Guest1 joined. (Connected: 2)"
expected = " * Guest1 joined. (Connected: 2)\r"
if actual != expected {
t.Errorf("Got %q; expected %q", actual, expected)
}