axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Senaka Fernando" <>
Subject Re: Some ideas about newly added tests for Axis2/c utils
Date Tue, 05 Feb 2008 13:53:42 GMT
Hi Milinda,

I believe your version sounds better than the existing one. If so, why
don't you commit it? I fixed up the duration test, and also fixed some
bugs in the duration code. I believe if our devs could take an issue (a
test I mean) at a time and fix it, it is not going to be a great deal of


On Tue, 2008-02-05 at 15:54 +0530, Milinda Pathirage wrote:
> I have correct some mistakes in date time test and added some small
things. Here I have attached the my version of date time test. It's
better if you can analyze it and comment on the implementation. Then we
can identify proper way to write test cases for current utility
implementations. Also I think it's better if we create a wiki page to
track the progress of these test cases. Then anyone can contribute to
design of these test cases.
> Thanks
> Milinda
> On Feb 5, 2008 2:13 PM, Dushshantha Chandradasa
<> wrote:
> Hi Milinda and All,
>         Thank you very much for your valuable comment.  The main
intension  behind writing these unit  test cases is to improve
the the test coverage of our code base. Its really important to
have unit tests not only to increase the code coverage
percentage, but also to keep the code bug free. Since we didn't
maintain a good set of unit tests from the  beginning , Manoj is
helping us writing few test cases beginning from the areas that
we never had unit tests before.
>         Writing unit test cases for existing code written by somebody
else is bit difficult. The good practice here is writing those
while the developer writing the code. So I suggest  all of  us 
that  we'll polish the new test cases up, to do a better job and
make a habit of adding few unit tests for the changes you are
doing to code. These good practices help us to keep our code in
a high quality.
>         Thanks,
>         Dushshantha
>         On Feb 4, 2008 9:13 PM, Milinda Pathirage
<> wrote:
>         Hi all,
>                 First of all I have to say that it's a good idea (tests
for utils). I analyze some of the test cases and found
out that they were not correctly implemented according
to my knowledge. I think we have to figure out why we
need those test cases and what we are going to test
using that test cases. Looking at these implementations,
I think no one can get any idea what they are stands for
(but the name says what is going to test). So, I think
we have to first identify what are we going to test and
how we going to test them . Then we can clearly design
some test case that correctly check our implementations
for correctness. Followings things are some mistakes I
found out in implementations under allocator test, and
date time test. I didn't look into much about other
tests but I think they also have same problems.
>                 When I first look at directory called allocator, I think
it contains test cases for our env->allocator. But what
is inside is test for fread and fwrite functions and
function called test_base64() which contains some
axutil_base64_binary_t creation function calls and
getter and setter methods of it. Also some unwanted
usage of global variables. Also axutil_env_t structure
creations are wrong. One axutil_env_creation is inside
the main method. It assigned created environment to
global variable called env and inside function
implementation another environment creation function is
called and again assigned the return value to the same
global variable.
>                 Inside date time test some mistakes that I have
mentioned above also visible and the date time string
use to test has wrong format.
>                 axis2_char_t * date_time_str = "2000-11-11 12:30:24";
>                 I don't know whether it was used intentionally. But it
must have following format.
>                 "2002-11-11T12:30:24"
>                 So I think we have to look at these tests seriously and
design these tests to test what we exactly want to test.
Please feel free to comment on this.
>                 Thanks
>                 Milinda
>                 --
>        "Infinite Dimensions"
>        "thinksquared"
>        "Web Services With Axis2/C"
> --
> "thinksquared"
> "Web Services With Axis2/C"
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message