[Webtest] ReportSite step

Paul King webtest@lists.canoo.com
Wed, 11 Jan 2006 01:08:40 +1000


Jon Poulton [kinomi] wrote:
> [In Canoo development home]
> 
>>ant clean
>>webtest clean develop

How about just:
prompt> ant clean develop

> This seemed to get a little further in the build/test cycle, although I
> still got an error message associated with one of the pdf steps. The failure
> message inside selftTestReport.xml was as follows:
> 
> <failure message="com.canoo.webtest.engine.StepFailedException: <unknown>:
> **** The current response and the expected result file
> 'expected\expectedPdfBookmarks.txt' differ. , Step: CompareToExpected at
> C:\Java\eclipse\workspace\canoo\webtest\selftests\tests\pdfBookmarks.xml:33:
> with (toFile="expected\expectedPdfBookmarks.txt", description="<unknown>",
> saveFiltered="true", readFiltered="false",
> stepType="compareToExpected")com.canoo.webtest.extension.CompareToExpected(d
> escription="<unknown>", wrappedSteps=[<PdfToBookmarksFilter at
> C:\Java\eclipse\workspace\canoo\webtest\selftests\tests\pdfBookmarks.xml:34:
> with (description="extract PDF bookmarks",
> stepType="pdf:toBookmarksFilter")> <LineSeparatorFilter at
> C:\Java\eclipse\workspace\canoo\webtest\selftests\tests\pdfBookmarks.xml:35:
> with (description="normalise line separators",
> stepType="lineSeparatorFilter")> ])" />
> 
> This isn't much help as the files it asks me to compare (and their parent
> directories) do not exist. I do not know if they were temporary files that
> were erased, or if the output generated for the test report is incorrect or
> out of date. Any ideas?

It should be comparing (if I matched up your directories correctly):
C:\Java\eclipse\workspace\canoo\webtest\selftests\tests\expected\expectedPdfBookmarks.txt
with the bookmarks it extracts from:
C:\Java\eclipse\workspace\canoo\webtest\selftests\tests\testDocBookmarks.pdf

If you replace compareToExpected with applyFilters, you should be able to
see what is being produced by the filter steps and visually compare with the
expected file.

Cheers, Paul.
P.S. Just noticed a minor bug in applyFilters when using the pdf steps as an
antlib with namespaces, e.g. pdf:verifyText instead of pdfVerifyText. The
result file was given an incorrect name (contained a ':' which WinDOS doesn't
like). Fixed in R_1118.