Added Test Data

Batch script to output all diff types
This commit is contained in:
Toby Allen 2012-12-21 19:51:54 +00:00
parent 3c31db856d
commit b018948943
10 changed files with 41 additions and 14 deletions

2
.gitignore vendored
View File

@ -83,7 +83,7 @@ _ReSharper*
[Ee]xpress
#General
*.zip
test/
temp/

Binary file not shown.

View File

@ -78,6 +78,7 @@ type
CHATTY = 5;
STANDARD = 1;
SILENT = 0;
ERRORS = 0;
implementation
@ -128,6 +129,10 @@ begin
Continue := true;
end;
//Ensure directory exists
ForceDirectories(ExtractFilePath( OutputFile));
if not Continue then HaltWithError(201, 'Input File, Output File and FileFormat must all be specified');
@ -155,12 +160,6 @@ end;
procedure TDocumentConverter.HaltWithError(ErrorNo: Integer; Msg: String);
begin
LogError(Msg);
@ -336,8 +335,8 @@ end;
procedure TDocumentConverter.LogError(Msg: String);
begin
Log('*******************************************');
Log('Error: ' + Msg);
Log('*******************************************', ERRORS);
Log('Error: ' + Msg, ERRORS);
end;
procedure TDocumentConverter.SetInputFile(const Value: String);

View File

@ -113,7 +113,7 @@
<VersionInfoKeys Name="Comments"/>
</VersionInfoKeys>
<Parameters>
<Parameters Name="RunParams">-L 10 -h</Parameters>
<Parameters Name="RunParams">-f &quot;d:\test\word\pie3.doc&quot; -Q -o &quot;d:\test\word\out\pie3y5ts.pdf&quot; </Parameters>
</Parameters>
<Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k150.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>

Binary file not shown.

View File

@ -1,10 +1,6 @@
wdFormatDOSTextLineBreaks=5
wdFormatEncodedText=7
wdFormatFilteredHTML=10
wdFormatFlatXML=19
wdFormatFlatXML=20
wdFormatFlatXMLTemplate=21
wdFormatFlatXMLTemplateMacroEnabled=22
wdFormatOpenDocumentText=23
wdFormatHTML=8
wdFormatRTF=6

Binary file not shown.

BIN
test/Pie3.doc Normal file

Binary file not shown.

23
test/testdata.txt Normal file
View File

@ -0,0 +1,23 @@
wdFormatDOSTextLineBreaks txt
wdFormatEncodedText txt
wdFormatFilteredHTML html
wdFormatOpenDocumentText odt
wdFormatHTML html
wdFormatRTF rtf
wdFormatStrictOpenXMLDocument oxd
wdFormatTemplate dot
wdFormatText txt
wdFormatTextLineBreaks txt
wdFormatUnicodeText txt
wdFormatWebArchive .webarchive
wdFormatXML xml
wdFormatDocument doc
wdFormatDocumentDefault doc
wdFormatPDF pdf
wdFormatTemplate dot
wdFormatXMLDocument xml
wdFormatXMLDocumentMacroEnabled xml
wdFormatXMLTemplate xml
wdFormatXMLTemplateMacroEnabled xml
wdFormatXPS xps

9
test/testrun.bat Normal file
View File

@ -0,0 +1,9 @@
REM Explaination
REM For use of FOR type FOR /? at prompt
REM The first part specifies ; lines to be ignored
REM I want the first 2 items (delimited by , or [space] on each line from the file specified.
REM Variables will be %%i (%%j is created automatically)
REM execute docto inserting variables
REM %~d0 and %~p0 together give the full directory this batch file is executing in.
FOR /F "eol=; tokens=1,2* delims=, " %%i in (testdata.txt) do "../exe/docto.exe" -f "%~d0%~p0pie3.doc" -o "%~d0%~p0GeneratedFiles\pie3out_%%i.%%j" -T %%i