mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-07-07 20:06:36 +02:00
Unit Tests
- Fixed project.t tests that were broken after the projects report was truncated.
This commit is contained in:
parent
3a45a2f639
commit
70f5588867
1 changed files with 7 additions and 7 deletions
|
@ -84,7 +84,7 @@ my @lines = split ('\n',$output);
|
|||
# It's easier to make a pattern for the end than the beginning because priority
|
||||
# counts are more predictable than project names.
|
||||
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];
|
||||
}
|
||||
|
@ -94,7 +94,7 @@ else
|
|||
}
|
||||
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];
|
||||
}
|
||||
|
@ -104,7 +104,7 @@ else
|
|||
}
|
||||
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";
|
||||
}
|
||||
|
@ -114,7 +114,7 @@ else
|
|||
}
|
||||
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];
|
||||
}
|
||||
|
@ -124,7 +124,7 @@ else
|
|||
}
|
||||
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];
|
||||
}
|
||||
|
@ -134,7 +134,7 @@ else
|
|||
}
|
||||
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];
|
||||
}
|
||||
|
@ -144,7 +144,7 @@ else
|
|||
}
|
||||
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];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue