Skip to content

Commit

Permalink
add failing test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
Songmu committed May 19, 2015
1 parent 49c95bd commit 43a0256
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions encode_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,16 @@ var marshalTests = []struct {
map[string]string{"a": "b: c"},
"a: 'b: c'\n",
},

// Containing hash mark ('#') in string should be quoted
{
map[string]string{"a": "Hello #comment"},
"a: 'Hello #comment'\n",
},
{
map[string]string{"a": "你好 #comment"},
"a: '你好 #comment'\n",
},
}

func (s *S) TestMarshal(c *C) {
Expand Down

0 comments on commit 43a0256

Please sign in to comment.