This file is indexed.

/usr/share/gocode/src/github.com/yosssi/gohtml/utils_test.go is in golang-github-yosssi-gohtml-dev 0.0~git20150923.0.ccf383e-4.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package gohtml

import (
	"bytes"
	"testing"
)

func TestWriteLine(t *testing.T) {
	bf := &bytes.Buffer{}
	writeLine(bf, "test", 1)
	actual := bf.String()
	expected := defaultIndentString + "test"
	if actual != expected {
		t.Errorf("Invalid result. [expected: %s][actual: %s]", expected, actual)
	}
}

func TestWriteLineFeed(t *testing.T) {
	bf := &bytes.Buffer{}
	writeLine(bf, "test", 0)
	writeLineFeed(bf)
	actual := bf.String()
	expected := "test\n"
	if actual != expected {
		t.Errorf("Invalid result. [expected: %s][actual: %s]", expected, actual)
	}
}

func TestWriteIndent(t *testing.T) {
	bf := &bytes.Buffer{}
	writeIndent(bf, 1)
	actual := bf.String()
	expected := defaultIndentString
	if actual != expected {
		t.Errorf("Invalid result. [expected: %s][actual: %s]", expected, actual)
	}
}

func TestUnifyLineFeed(t *testing.T) {
	actual := unifyLineFeed("\r\n\n\r")
	expected := "\n\n\n"
	if actual != expected {
		t.Errorf("Invalid result. [expected: %s][actual: %s]", expected, actual)
	}
}