1
// Copyright 2013 ChaiShushan <chaishushan{AT}gmail.com>. All rights reserved.
2
// Use of this source code is governed by a BSD-style
3
// license that can be found in the LICENSE file.
12
func _TestPoEntry(t *testing.T) {
13
if len(testPoEntrys) != len(testPoEntryStrings) {
17
for i := 0; i < len(testPoEntrys); i++ {
18
if err := entry.readPoEntry(newLineReader(testPoEntryStrings[i])); err != nil {
21
if !reflect.DeepEqual(&entry, &testPoEntrys[i]) {
22
t.Fatalf("%d: expect = %v, got = %v", i, testPoEntrys[i], entry)
27
var testPoEntryStrings = []string{
29
# SOME DESCRIPTIVE TITLE.
30
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
31
# This file is distributed under the same license as the PACKAGE package.
32
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
36
"Project-Id-Version: 项目名称\n"
37
"Report-Msgid-Bugs-To: \n"
38
"POT-Creation-Date: 2011-12-12 20:03+0000\n"
39
"PO-Revision-Date: 2013-12-02 17:05+0800\n"
40
"Last-Translator: chai2010 <chaishushan@gmail.com>\n"
41
"Language-Team: chai2010(团队) <chaishushan@gmail.com>\n"
44
"Content-Type: text/plain; charset=UTF-8\n"
45
"Content-Transfer-Encoding: 8bit\n"
46
"X-Generator: Poedit 1.5.7\n"
47
"X-Poedit-SourceCharset: UTF-8\n"
51
var testPoEntrys = []Message{
54
TranslatorComment: `SOME DESCRIPTIVE TITLE.
55
Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
56
This file is distributed under the same license as the PACKAGE package.
57
FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
61
Project-Id-Version: 项目名称
63
POT-Creation-Date: 2011-12-12 20:03+0000
64
PO-Revision-Date: 2013-12-02 17:05+0800
65
Last-Translator: chai2010 <chaishushan@gmail.com>
66
Language-Team: chai2010(团队) <chaishushan@gmail.com>
69
Content-Type: text/plain; charset=UTF-8
70
Content-Transfer-Encoding: 8bit
71
X-Generator: Poedit 1.5.7
72
X-Poedit-SourceCharset: UTF-8