Skip to content

Commit 17cd175

Browse files
haarggenio
authored andcommitted
fix test scripts after conversion to Test::More
Two of the test scripts were converted from Test to Test::More, but their usage of ok was not properly updated. Test's ok works like ok, is, and like, depending on what arguments it is given. Fix the calls to use is so they are actually testing something.
1 parent ff4e222 commit 17cd175

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

t/document.t

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,30 +11,30 @@ my $p
1111

1212
$events = "";
1313
$p->eof;
14-
ok($events, "start_document\nend_document\n");
14+
is($events, "start_document\nend_document\n");
1515

1616
$events = "";
1717
$p->parse_file(File::Spec->devnull);
18-
ok($events, "start_document\nend_document\n");
18+
is($events, "start_document\nend_document\n");
1919

2020
$events = "";
2121
$p->parse("");
2222
$p->eof;
23-
ok($events, "start_document\nend_document\n");
23+
is($events, "start_document\nend_document\n");
2424

2525
$events = "";
2626
$p->parse("");
2727
$p->parse("");
2828
$p->eof;
29-
ok($events, "start_document\nend_document\n");
29+
is($events, "start_document\nend_document\n");
3030

3131
$events = "";
3232
$p->parse("");
3333
$p->parse("<a>");
3434
$p->eof;
35-
ok($events, "start_document\nstart\nend_document\n");
35+
is($events, "start_document\nstart\nend_document\n");
3636

3737
$events = "";
3838
$p->parse("<a> ");
3939
$p->eof;
40-
ok($events, "start_document\nstart\ntext\nend_document\n");
40+
is($events, "start_document\nstart\ntext\nend_document\n");

t/script.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ $p->parse(
2929
);
3030
$p->eof;
3131

32-
ok($TEXT, <<'EOT');
32+
is($TEXT, <<'EOT');
3333
[start_document,<undef>,]
3434
[start,tr,<tr>]
3535
[start,td,<td align="center" height="100">]

0 commit comments

Comments
 (0)