From 3fba8e42b140c1189bf3c06882cce5e2231e63da Mon Sep 17 00:00:00 2001 From: =Corey Hulen Date: Fri, 8 Jan 2016 12:41:26 -0600 Subject: partial fix for UI --- model/command_response_test.go | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 model/command_response_test.go (limited to 'model/command_response_test.go') diff --git a/model/command_response_test.go b/model/command_response_test.go new file mode 100644 index 000000000..7aa3e984b --- /dev/null +++ b/model/command_response_test.go @@ -0,0 +1,19 @@ +// Copyright (c) 2016 Mattermost, Inc. All Rights Reserved. +// See License.txt for license information. + +package model + +import ( + "strings" + "testing" +) + +func TestCommandResponseJson(t *testing.T) { + o := CommandResponse{Text: "test"} + json := o.ToJson() + ro := CommandResponseFromJson(strings.NewReader(json)) + + if o.Text != ro.Text { + t.Fatal("Ids do not match") + } +} -- cgit v1.2.3-1-g7c22