<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>32833</bug_id>
          
          <creation_ts>2009-12-21 12:04:04 -0800</creation_ts>
          <short_desc>[check-webkit-style] qt unit testing false positives</short_desc>
          <delta_ts>2010-01-17 19:12:02 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Tools / Tests</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>33771</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Adam Barth">abarth</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>carol</cc>
    
    <cc>commit-queue</cc>
    
    <cc>kenneth</cc>
    
    <cc>laszlo.gombos</cc>
    
    <cc>levin</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>174028</commentid>
    <comment_count>0</comment_count>
    <who name="Adam Barth">abarth</who>
    <bug_when>2009-12-21 12:04:04 -0800</bug_when>
    <thetext>Please find below an explanation why the style errors detected by the review bot are either invalid, or cannot be addressed.
Some of these explanations may be wrong, this is why I copied Simon and Laszlo so that they have a chance of correcting me.
 
Thanks for your time and attention,
Carol Szabo
 
 
 
Failed to run &quot;WebKitTools/Scripts/check-webkit-style&quot; exit_code: 1
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:21:  Found other
header before WebCore config.h. Should be: config.h, primary header, blank
line, and then alphabetically sorted.  [build/include_order] [4]
 
This first issue I believe to be false. Since the test is not part of WebKit it should not include config.h, I believe that it should not even have access to it since the test is a Qt application and config.h is/should not be, part of the QtWebKit Api

WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:26:  Alphabetical
sorting problem.  [build/include_order] [4]
This issue I believe also to be false, but I may stand corrected. I thought that system headers need to be separated for WebKit headers by an empty line and follow them.
I consider &lt;QDebug&gt;, &lt;QNetworkReply&gt; and &lt;QtTest&gt; system headers since they belong to the platform (Qt), but I may stand corrected since QtWebKit is also currently, part of Qt, hence all headers included in this file could be considered &quot;system&quot; as indicated by the angled brackets, but confused by the fact that the headers do not follow the same naming convention, leading me to treat them differently.
 
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:30:  Should have
a space between // and comment  [whitespace/comments] [4]
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:31:  Should have
a space between // and comment  [whitespace/comments] [4]
 
//TESTED_CLASS=QWebSecurityOrigin
//TESTED_FILES=WebKit/qt/Api/qwebsecurityorigin.*
 
The two comments above appear to be special case comments with some meaning to a tool. I copied them verbatim and have updated them from a different test. Please someone confirm whether it is safe to insert the space after //
 
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:42:  create_data
is incorrectly named. Don&apos;t use underscores in your identifier names. 
[readability/naming] [4]
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:44: 
whiteList_data is incorrectly named. Don&apos;t use underscores in your identifier
names.  [readability/naming] [4]
Sorry, this cannot be helped. Using tesname_data as the name of the function providing the data for the test is a QtTest framework requirement unlikely to change so the names of these functions will have to stay like this.
 
WebKit/qt/tests/qwebsecurityorigin/tst_qwebsecurityorigin.cpp:251:  Found
header this file implements after other header. Should be: config.h, primary
header, blank line, and then alphabetically sorted.  [build/include_order] [4]
#include &quot;tst_qwebsecurityorigin.moc&quot;
 
This is actually an error in detection the header name.
This is a pattern required by Qt for files that use moc but have no matching header file and it is used also in other tests and in QtLauncher/main.cpp.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>174031</commentid>
    <comment_count>1</comment_count>
    <who name="Laszlo Gombos">laszlo.gombos</who>
    <bug_when>2009-12-21 12:08:49 -0800</bug_when>
    <thetext>The fundamental issue here is whether API tests - that are not part of WebKit binary per say - needs to also follow the WebKit style or not. It might make sense not to expose WebKit style guide for API tests.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>175544</commentid>
    <comment_count>2</comment_count>
    <who name="Kenneth Rohde Christiansen">kenneth</who>
    <bug_when>2009-12-29 07:04:04 -0800</bug_when>
    <thetext>(In reply to comment #1)
&gt; The fundamental issue here is whether API tests - that are not part of WebKit
&gt; binary per say - needs to also follow the WebKit style or not. It might make
&gt; sense not to expose WebKit style guide for API tests.

I think it would be better to disable some of the tests for certain subdirs, such as WebKit/qt/Api</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>181647</commentid>
    <comment_count>3</comment_count>
      <attachid>46769</attachid>
    <who name="Adam Barth">abarth</who>
    <bug_when>2010-01-17 16:26:23 -0800</bug_when>
    <thetext>Created attachment 46769
Patch (requires blocking bug to be fixed)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>181695</commentid>
    <comment_count>4</comment_count>
      <attachid>46769</attachid>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2010-01-17 19:11:56 -0800</bug_when>
    <thetext>Comment on attachment 46769
Patch (requires blocking bug to be fixed)

Clearing flags on attachment: 46769

Committed r53386: &lt;http://trac.webkit.org/changeset/53386&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>181696</commentid>
    <comment_count>5</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2010-01-17 19:12:02 -0800</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>46769</attachid>
            <date>2010-01-17 16:26:23 -0800</date>
            <delta_ts>2010-01-17 19:11:56 -0800</delta_ts>
            <desc>Patch (requires blocking bug to be fixed)</desc>
            <filename>bug-32833-20100117162621.patch</filename>
            <type>text/plain</type>
            <size>2245</size>
            <attacher name="Adam Barth">abarth</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL1dlYktpdFRvb2xzL0NoYW5nZUxvZyBiL1dlYktpdFRvb2xzL0NoYW5nZUxv
ZwppbmRleCA5YWM0MWE4Li5hZmFjNjY1IDEwMDY0NAotLS0gYS9XZWJLaXRUb29scy9DaGFuZ2VM
b2cKKysrIGIvV2ViS2l0VG9vbHMvQ2hhbmdlTG9nCkBAIC0yLDYgKzIsMTggQEAKIAogICAgICAg
ICBSZXZpZXdlZCBieSBOT0JPRFkgKE9PUFMhKS4KIAorICAgICAgICBbY2hlY2std2Via2l0LXN0
eWxlXSBxdCB1bml0IHRlc3RpbmcgZmFsc2UgcG9zaXRpdmVzCisgICAgICAgIGh0dHBzOi8vYnVn
cy53ZWJraXQub3JnL3Nob3dfYnVnLmNnaT9pZD0zMjgzMworCisgICAgICAgIEV4ZW1wdCB0aGUg
UXQgQVBJIGFuZCB1bml0IHRlc3RzIGZyb20gdGhlIHN0eWxlIGNoZWNrZXIuCisKKyAgICAgICAg
KiBTY3JpcHRzL3dlYmtpdHB5L3N0eWxlL2NwcF9zdHlsZS5weToKKyAgICAgICAgKiBTY3JpcHRz
L3dlYmtpdHB5L3N0eWxlL2NwcF9zdHlsZV91bml0dGVzdC5weToKKworMjAxMC0wMS0xNyAgQWRh
bSBCYXJ0aCAgPGFiYXJ0aEB3ZWJraXQub3JnPgorCisgICAgICAgIFJldmlld2VkIGJ5IE5PQk9E
WSAoT09QUyEpLgorCiAgICAgICAgIHN0eWxlLWNoZWNrIHNjcmlwdCByZXBvcnRzIGxvYWRzIG9m
IGVycm9ycyBvbiBndGsyZ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