<div dir="ltr"><div>Hi, </div><div><br><div>I also spent some time to think about the functional test case as well. ( I think this can be one part of the GSOC topic  Automatic testing as well.)<br></div><div><br></div><div>
<br></div><div>> How do you plan to automate the functional tests?</div><div style>I think Selenium can cover Functional case as well. take index.php for example, we can use Selenium to load the index.php, and check the page element, such as <<span style="color:rgb(0,0,0);font-family:Consolas,'Lucida Console',monospace;font-size:12px;white-space:pre-wrap">mainFrameset</span>> and <<span style="color:rgb(0,0,0);font-family:Consolas,'Lucida Console',monospace;font-size:12px;white-space:pre-wrap">frame_navigation</span>></div>
<div style><br></div><div style>in other word, we can use selenium to check Page element is loaded correctly, I think this work is as important as Unit test. </div><div style><br></div><div style>other benefit, we can cover phpmyadmin can work well one GradeA browsers. </div>
<div style>1. check the page is loaded correctly</div><div style>2. check the page is working well on  GradeA browsers. </div><div style>3. check the css/js is working well</div><div style>......</div><div><br></div><div>
<div>> 5. check coding style compliance, with PHP_CodeSniffer    <---- I think we<br>> should do it before code-review<br><br></div>> I meant it to be part of the code reviewing. ;)<br><br>> 6. code review<br>
<br>> -> 6.a run UT & regression test on dev box<br><br>>best to test everything again after code reviewing and before commiting and checking in code.<br><div><br>> 7  checkin code<br>> 8  check CI build result</div>
</div><div class="gmail_extra"><br></div><div class="gmail_extra" style>totally agree, codesniffer can be one part of CI job, if the codesniffer failed, the CI should failed as well.</div><div class="gmail_extra"><br></div>
<div class="gmail_extra"><br></div><div class="gmail_extra">
thanks,</div><div class="gmail_extra"><br></div><div class="gmail_extra">Adam<br><br><div class="gmail_quote">On Fri, Mar 29, 2013 at 6:41 PM, Dieter Adriaenssens <span dir="ltr"><<a href="mailto:dieter.adriaenssens@gmail.com" target="_blank">dieter.adriaenssens@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">2013/3/29 adam <<a href="mailto:adamgsoc2013@gmail.com" target="_blank">adamgsoc2013@gmail.com</a>>:<br>


<div>> Hi Dieter,<br>
><br>
> thanks for your reply. I was trying to apply the GSOC topic: Automatic<br>
> testing. so I want to check with you guys about the fomal process<br>
><br>
>> What do you mean by regression tests? How are they different from unit<br>
>> tests?<br>
>> The process you describe sounds reasonable. If you rearrange the order<br>
>> a bit, and add codechecking to your process, you are on your way of<br>
>> writing good code (see below for suggestions)<br>
><br>
> In my mind, the regression tests is different from the unit tests. or in<br>
> other word, we can say that the regression test include Unit tests.<br>
> the regression test can include function test case beside unit tests.<br>
><br>
> In my mind, in order to gurantee the code quality, UNIT test just cover the<br>
> code logic, but Fuinctional test can be end to end case with real case.<br>
<br>
</div>Ok, makes sense. How do you plan to automate the functional tests?<br>
<div><br>
>> In my mind, the fomal processes should be:<br>
>> 1. add UT code<br>
>> (TDD [0] principle, write tests first, then start implementing the<br>
>> class/method)<br>
>> 2.  add logic code<br>
>> 3. test on dev box<br>
>> 4. run UT & regression test on dev box<br>
>> 5. code review after pass 1-4<br>
><br>
>> -> check coding style compliance, with PHP_CodeSniffer and fix the<br>
>> reported issues.<br>
>> You can run Jenkins on your own box, or execute `phpcs filename` on<br>
>> the command line, more info on setting up Jenkins [1]<br>
><br>
>> > 6. checkin code<br>
>>> 7. check CI build<br>
>>> .....<br>
><br>
><br>
> I agree with you. so the process should be:<br>
> 1. Add UT code<br>
> 2. Add logic code<br>
> 3.  test on dev box<br>
> 4. run UT & regression test on dev box<br>
> 5. check coding style compliance, with PHP_CodeSniffer    <---- I think we<br>
> should do it before code-review<br>
<br>
</div>I meant it to be part of the code reviewing. ;)<br>
<br>
> 6. code review<br>
<br>
-> 6.a run UT & regression test on dev box<br>
<br>
best to test everything again after code reviewing and before<br>
commiting and checking in code.<br>
<div><br>
> 7  checkin code<br>
> 8  check CI build result<br>
<br>
<br>
<br>
> thanks,<br>
><br>
> Adam<br>
<br>
<br>
<br>
</div><div><div>--<br>
Kind regards,<br>
<br>
Dieter Adriaenssens<br>
</div></div></blockquote></div><br></div></div></div>