cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: [PATCH] Allow various Curl test suite tests to work on non-ASCII platforms

From: David McCreedy <mccreedytpf_at_gmail.com>
Date: Thu, 7 May 2009 16:24:36 -0600

On Thu, May 7, 2009 at 11:59 AM, Yang Tse <yangsita_at_gmail.com> wrote:

> 2009/5/7, David McCreedy wrote:
>
> > > This patch sets the CURLOPT_TRANSFERTEXT option, conditionally on
> > > CURL_DOES_CONVERSIONS definition for tests lib508.c, lib510.c,
> > > lib552.c, lib553.c, and lib555.c.
> > >
> > > Is there any reason for not doing the same now on nearly all lib5XX.c
> > > source files, even when the test data might not be non-ASCII ready
> > > yet, and the test might not be HTTP POST related?
> >
> > The biggest reason that comes to mind is to maintain a mix of tests with
> and
> > without the option specified.
> > On TPF the user won't always specify the option so both paths through the
> > logic are important to hit.
>
> Reasonable enough, as both code paths could be followed.
>
> I mixed up the CURL_DOES_CONVERSIONS definition with the
> CURLOPT_TRANSFERTEXT option. I don't know what I was thinking about.
> ;-)
>
> > I can try adding the option to other lib5xx.c's if you like that approach
> > better.
> > But I do like the mix of tests with and without the option.
> > Please let me know.
>
> Keep the mix. It tests more things.
>
> > > Regarding the string literals writing inside the lib5XX.c tests only
> > > as ASCII hex-dump I personally would prefer to keep this kind of
> > > 'writing' inside CURL_DOES_CONVERSIONS conditionals, and the existing
> > > representation/writing on the 'else' part of the condition.
> > >
> > > Would this still work for you?
> > >
> >
> > Yes, it should. I'll work up new patches.
>
> Ok, lib5XX.c patches can all go together in the same batch and applied
> right away.

The revised lib5XX.c changes are attached.

>
>
> testcurl.pl tricks and test5XX patches on different files and later on.
>

Will do.

Thanks.

-David

>
> --
> -=[Yang]=-
>

Received on 2009-05-08