pdf-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pdf-devel] Build Error - unit test cases


From: Gaurav Aggarwal
Subject: Re: [pdf-devel] Build Error - unit test cases
Date: Tue, 4 Aug 2009 15:00:04 +0530 (IST)

> From: Aleksander Morgado <address@hidden>

> To: Pablo Vasquez <address@hidden>
> Cc: address@hidden; address@hidden
> Sent: Tuesday, 4 August, 2009 12:32:06 PM
> Subject: Re: [pdf-devel] Build Error - unit test cases
> 
> Hi All,
> 
> 
> > In fact this isn't the main issue in the mail I mentioned. I wasn't
> > talking about the errors I got. I was talking about something Jose
> > said there.
> > In that mail  Jose says:
> > 
> >> The compilation of the unit tests fails when compiling
> >> torture/unit/base/stm/pdf-stm-write.c, due to the usage of check
> >> fixtures introduced by a recent patch.  Currently nocheck is not
> >> supporting fixtures.
> > 
> > And then comes some talking about check and nocheck.
> > Please read the mail again.
> > Sorry if I wasn't clear enough.
> 
> Yes, that's all true. We developed builtin no-check as a very simple
> replacement of `check' library so that it could be used in Windows
> systems (or in systems where `check' was just not available). In fact,
> if you check the source code of no-check, it's just a more-or-less API
> compatible module replacing `check' library.
> 
> 
> >>
> >> Build Error
> >> ---------------------
> >>> gcc -DHAVE_CONFIG_H -I. -I../../src  -I../../lib
> >> -I../../src -I../../src/base -I../../src/object
> >> -I../../torture/tortutils -DTEST_DATA_PATH=\"../../torture/testdata\"
> >> -Inocheck/  -g -g -MT pdf-stm-write.o -MD -MP -MF
> >> .deps/pdf-stm-write.Tpo -c -o pdf-stm-write.o `test -f
> >> 'base/stm/pdf-stm-write.c' || echo './'`base/stm/pdf-stm-write.c
> >>> base/stm/pdf-stm-write.c: In function 'mem_stm_fixture_setup':
> >>> base/stm/pdf-stm-write.c:52: error: 'test_name' undeclared (first use in 
> this function)
> >>> base/stm/pdf-stm-write.c:52: error: (Each undeclared identifier is 
> >>> reported 
> only once
> >>> base/stm/pdf-stm-write.c:52: error: for each function it appears in.)
> >>> make[2]: ***
> 
> Some time ago, some new tests were added using fixtures in `check', and
> fixtures were not originally added in our no-check replacement. And we
> don't want to add support to them now (not sure if possible), because
> now the original `check' library (at least the repository version they
> have) works on Windows machines. This is, you can create your `check'
> DLL (if not already created by someone out there) and use it along with
> our tests in Windows OS. This new Windows-compatible check still lacks
> forking support, so the behavior will be completely similar to what we
> previously had with no-check, but supporting more things, like fixtures
> (I hope so, I didn't try it).
> 
> Should we maybe disable `no-check' from now on? If it doesn't even
> compile, it doesn't make much sense to have it there, I would say. Or
> maybe we can hack it so that at least it ignores fixtures while compiling...

OK. Attached is the possible hack/fix for the build-error. This patch will 
provide the limited support for the Fixtures and one should be able to build 
the code successfully.
NOTE: For future development, I would suggest that test writers will follow the 
same procedure as mentioned in this patch, to keep it compatible with nocheck 
flag incase one plans to use the fixture. Hope this will help.


> 
> 
> Cheers!
> -Aleksander



      Yahoo! recommends that you upgrade to the new and safer Internet Explorer 
8. http://downloads.yahoo.com/in/internetexplorer/

Attachment: patch-fix-nocheck-build-error
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]