Skip to content

Commit bd0490d

Browse files
committed
tests: fix html formatter tests
1 parent 825257b commit bd0490d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

formatter/formatter_html_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ func TestHTMLFormatter_Format(t *testing.T) {
210210
},
211211
wantErr: false,
212212
validate: func(f *HTMLFormatter, output string, t *testing.T) {
213-
expect := 1
213+
expect := 2
214214
re := regexp.MustCompile(`<li><a href="#\d+">`)
215215
actual := len(re.FindAllString(output, -1))
216216
if expect != actual {
@@ -219,7 +219,7 @@ func TestHTMLFormatter_Format(t *testing.T) {
219219
},
220220
},
221221
{
222-
name: "Check TOC 2 hosts, 1 down, not skipping down hosts",
222+
name: "Check TOC 2 hosts, 1 down",
223223
f: &HTMLFormatter{},
224224
args: args{
225225
td: &TemplateData{
@@ -462,7 +462,7 @@ func TestHTMLFormatter_Format(t *testing.T) {
462462
},
463463
},
464464
{
465-
name: "3 hosts 1 down (skip down: true)",
465+
name: "3 hosts 1 down",
466466
f: &HTMLFormatter{},
467467
args: args{
468468
td: &TemplateData{
@@ -540,7 +540,7 @@ func TestHTMLFormatter_Format(t *testing.T) {
540540
},
541541
wantErr: false,
542542
validate: func(f *HTMLFormatter, output string, t *testing.T) {
543-
expect := 2
543+
expect := 3
544544
re := regexp.MustCompile(`<h2 class="host-address-header (host-up|host-down)">(\s*)192\.168\.1\.[0-9]+`)
545545
actual := len(re.FindAllString(output, -1))
546546
if expect != actual {

0 commit comments

Comments
 (0)