test: added codetools tests for FindLineEndOrCodeInFrontOfPosition

git-svn-id: trunk@29295 -
This commit is contained in:
mattias 2011-02-01 19:15:36 +00:00
parent c39c47fd60
commit a43e91a50a
2 changed files with 10 additions and 2 deletions

View File

@ -49,9 +49,18 @@ procedure TTestBasicCodeTools.TestFindLineEndOrCodeInFrontOfPosition;
AssertEquals('['+dbgstr(OrigSrc)+']',Expected,Actual);
end;
var
e: String;
begin
writeln('TTestBasicCodeTools.TestFindLineEndOrCodeInFrontOfPosition ');
t(' $'#10'|a:=1;');
e:=#13#10; // use windows line endings, they are more complicated
t(' $'+e+'|a:=1;');
t('a$'+e+'// comment'+e+' { comment } '+e+'|');
t('$'+e+' (* *)'+e+' |a:=1');
t('a:=1;(* comment of first line'+e+' *)$ |b:=1');
t('a:=1; // comment$'+e+'|b:=1');
t('a:=1; (* comment'+e+' *) $'+e+'|b:=1');
t('a:=1; (* comment'+e+' *) { comment'+e+' } $'+e+'|b:=1');
end;
initialization

View File

@ -110,7 +110,6 @@
<OverflowChecks Value="True"/>
<StackChecks Value="True"/>
</Checks>
<VerifyObjMethodCallValidity Value="True"/>
</CodeGeneration>
<Other>
<CompilerMessages>