Bug 136850 - W3C test importer should copy .htaccess files
Summary: W3C test importer should copy .htaccess files
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-16 03:18 PDT by youenn fablet
Modified: 2014-09-23 10:10 PDT (History)
4 users (show)

See Also:


Attachments
Patch (1.56 KB, patch)
2014-09-16 03:21 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Added helper function (2.31 KB, patch)
2014-09-23 01:09 PDT, youenn fablet
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description youenn fablet 2014-09-16 03:18:07 PDT
Currently W3C test import skip all files starting with '.'
.htaccess is used to control serving files on HTTP and should be copied.
Comment 1 youenn fablet 2014-09-16 03:21:49 PDT
Created attachment 238171 [details]
Patch
Comment 2 Bem Jones-Bey 2014-09-22 10:47:03 PDT
Comment on attachment 238171 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=238171&action=review

> Tools/Scripts/webkitpy/w3c/test_importer.py:184
>                  if filename.startswith('.') or filename.endswith('.pl'):
> -                    continue  # For some reason the w3c repo contains random perl scripts we don't care about.
> +                    if not filename == '.htaccess':
> +                        continue  # For some reason the w3c repo contains random perl scripts we don't care about.

This is getting messy. I would add a helper like should_skip_file(), and move all of the tests there. Then this would be something like:
if self.should_skip_file(filename):
  continue
Comment 3 youenn fablet 2014-09-23 01:09:37 PDT
Created attachment 238520 [details]
Added helper function
Comment 4 Bem Jones-Bey 2014-09-23 09:34:14 PDT
Comment on attachment 238520 [details]
Added helper function

r=me
Comment 5 WebKit Commit Bot 2014-09-23 10:10:44 PDT
Comment on attachment 238520 [details]
Added helper function

Clearing flags on attachment: 238520

Committed r173876: <http://trac.webkit.org/changeset/173876>
Comment 6 WebKit Commit Bot 2014-09-23 10:10:47 PDT
All reviewed patches have been landed.  Closing bug.