Unit Tests
- Fixed project.t tests that were broken after the projects report was truncated.
This commit is contained in:
@@ -84,7 +84,7 @@ my @lines = split ('\n',$output);
|
|||||||
# It's easier to make a pattern for the end than the beginning because priority
|
# It's easier to make a pattern for the end than the beginning because priority
|
||||||
# counts are more predictable than project names.
|
# counts are more predictable than project names.
|
||||||
my $project_name_column;
|
my $project_name_column;
|
||||||
if ($lines[4] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[4] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[4];
|
$project_name_column = $lines[4];
|
||||||
}
|
}
|
||||||
@@ -94,7 +94,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^\.myProject\s*$/, '\'.myProject\' not indented');
|
like ($project_name_column, qr/^\.myProject\s*$/, '\'.myProject\' not indented');
|
||||||
|
|
||||||
if ($lines[5] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[5] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[5];
|
$project_name_column = $lines[5];
|
||||||
}
|
}
|
||||||
@@ -104,7 +104,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^\.myProject\.\s*$/, '\'.myProject.\' not indented');
|
like ($project_name_column, qr/^\.myProject\.\s*$/, '\'.myProject.\' not indented');
|
||||||
|
|
||||||
if ($lines[6] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[6] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = "error";
|
$project_name_column = "error";
|
||||||
}
|
}
|
||||||
@@ -114,7 +114,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^abstractParent\s*$/, 'abstract parent not indented and no priority columns');
|
like ($project_name_column, qr/^abstractParent\s*$/, 'abstract parent not indented and no priority columns');
|
||||||
|
|
||||||
if ($lines[7] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[7] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[7];
|
$project_name_column = $lines[7];
|
||||||
}
|
}
|
||||||
@@ -124,7 +124,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^ kid\s*$/, 'child indented and without parent name');
|
like ($project_name_column, qr/^ kid\s*$/, 'child indented and without parent name');
|
||||||
|
|
||||||
if ($lines[8] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[8] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[8];
|
$project_name_column = $lines[8];
|
||||||
}
|
}
|
||||||
@@ -134,7 +134,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^existingParent\s*$/, 'existing parent not indented and has priority columns');
|
like ($project_name_column, qr/^existingParent\s*$/, 'existing parent not indented and has priority columns');
|
||||||
|
|
||||||
if ($lines[9] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[9] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[9];
|
$project_name_column = $lines[9];
|
||||||
}
|
}
|
||||||
@@ -144,7 +144,7 @@ else
|
|||||||
}
|
}
|
||||||
like ($project_name_column, qr/^ child\s*$/, 'child of existing parent indented and without parent name');
|
like ($project_name_column, qr/^ child\s*$/, 'child of existing parent indented and without parent name');
|
||||||
|
|
||||||
if ($lines[12] =~ s/\d+\s+\d+\s+\d+\s+\d+\s+\d+$//)
|
if ($lines[12] =~ s/\d+$//)
|
||||||
{
|
{
|
||||||
$project_name_column = $lines[12];
|
$project_name_column = $lines[12];
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user