Summary: | run-api-tests output is very confusing on Windows | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Adam Roben (:aroben) <aroben> | ||||
Component: | Tools / Tests | Assignee: | Adam Roben (:aroben) <aroben> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | dbates, ddkilzer, sam | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Attachments: |
|
Description
Adam Roben (:aroben)
2011-07-05 14:24:33 PDT
Created attachment 99747 [details]
Patch
Comment on attachment 99747 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=99747&action=review > Tools/Scripts/run-api-tests:308 > + my $suffix; > + if (configurationForVisualStudio() ne "Debug_All") { > + $suffix = ""; > + } else { > + $suffix = "_debug"; > + } Nit: It's usually easier to think about equal than not-equal, so I would have written this as: my $suffix; if (configurationForVisualStudio() eq "Debug_All") { $suffix = "_debug"; } else { $suffix = ""; } Alternatively, you could have written this as: my $suffix = ""; $suffix = "_debug" if configurationForVisualStudio() eq "Debug_All"; > Tools/Scripts/run-api-tests:309 > + return $path . $suffix . ".exe"; You can use string interpolation and write this as "$path$suffix.exe". Comment on attachment 99747 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=99747&action=review >> Tools/Scripts/run-api-tests:308 >> + } > > Nit: It's usually easier to think about equal than not-equal, so I would have written this as: > > my $suffix; > if (configurationForVisualStudio() eq "Debug_All") { > $suffix = "_debug"; > } else { > $suffix = ""; > } > > Alternatively, you could have written this as: > my $suffix = ""; > $suffix = "_debug" if configurationForVisualStudio() eq "Debug_All"; I changed this to match your first version. >> Tools/Scripts/run-api-tests:309 >> + return $path . $suffix . ".exe"; > > You can use string interpolation and write this as "$path$suffix.exe". Done. Committed r90408: <http://trac.webkit.org/changeset/90408> |