Changeset 25023 in webkit


Ignore:
Timestamp:
Aug 12, 2007 4:31:41 AM (17 years ago)
Author:
aroben
Message:

Generate results for new tests in a more logical location

New platform-specific tests always have their results generated right
next to the test. New cross-platform tests will have their results
generated a) in the cross-platform directory, if they are text-only,
or b) in the least-specific platform directory, if they are render
tree dumps.

Reviewed by Lars.

  • Scripts/run-webkit-tests:
Location:
trunk/WebKitTools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKitTools/ChangeLog

    r25022 r25023  
     12007-08-12  Adam Roben  <aroben@apple.com>
     2
     3        Generate results for new tests in a more logical location
     4
     5        New platform-specific tests always have their results generated right
     6        next to the test. New cross-platform tests will have their results
     7        generated a) in the cross-platform directory, if they are text-only,
     8        or b) in the least-specific platform directory, if they are render
     9        tree dumps.
     10
     11        Reviewed by Lars.
     12
     13        * Scripts/run-webkit-tests:
     14
    1152007-08-12  Adam Roben  <aroben@apple.com>
    216
  • trunk/WebKitTools/Scripts/run-webkit-tests

    r25022 r25023  
    7878sub stripExtension($);
    7979sub isTextOnlyTest($);
    80 sub expectedDirectoryForTest($);
     80sub expectedDirectoryForTest($;$);
    8181sub printFailureMessageForTest($$);
    8282sub toURL($);
     
    519519
    520520    my $expected;
    521     my $expectedDir = expectedDirectoryForTest($base);
     521    my $expectedDir = expectedDirectoryForTest($base, $isText);
    522522    if (isQt() && $isText) {
    523523        $expectedDir = $testDirectory;
     
    13061306}
    13071307
    1308 sub expectedDirectoryForTest($)
    1309 {
    1310     my ($base) = @_;
    1311 
    1312     foreach my $level (@platformHierarchy) {
    1313         return $level if (-f "$level/$base-$expectedTag.txt");
    1314     }
    1315 
    1316     return $expectedDirectory if (-f "$expectedDirectory/$base-$expectedTag.txt");
    1317 
    1318     return $platformHierarchy[$#platformHierarchy];
     1308sub expectedDirectoryForTest($;$)
     1309{
     1310    my ($base, $isText) = @_;
     1311
     1312    my @directories = @platformHierarchy;
     1313    push(@directories, $expectedDirectory);
     1314
     1315    # If we already have expected results, just return their location.
     1316    foreach my $directory (@directories) {
     1317        return $directory if (-f "$directory/$base-$expectedTag.txt");
     1318    }
     1319
     1320    # For platform-specific tests, the results should go right next to the test itself.
     1321    # Note: The return value of this subroutine will be concatenated with $base
     1322    # to determine the location of the new results, so returning $expectedDirectory
     1323    # will put the results right next to the test.
     1324    return $expectedDirectory if $base =~ /^platform/;
     1325
     1326    # For cross-platform tests, text-only results should go in the cross-platform directory,
     1327    # while render tree dumps should go in the least-specific platform directory.
     1328    return $isText ? $expectedDirectory : $platformHierarchy[$#platformHierarchy];
    13191329}
    13201330
Note: See TracChangeset for help on using the changeset viewer.