mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 17:29:10 +02:00
* Fix for failing COMP tests from Luiz Americo (bug ID 30878)
git-svn-id: trunk@34860 -
This commit is contained in:
parent
6bf0ec2de1
commit
d2ebb94fa3
@ -191,7 +191,7 @@ Type
|
|||||||
Public
|
Public
|
||||||
Constructor Create(AOwner : TComponent); override;
|
Constructor Create(AOwner : TComponent); override;
|
||||||
Published
|
Published
|
||||||
Property ExtendedProp : Comp Read F Write F;
|
Property CompProp : Comp Read F Write F;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
// Currency property
|
// Currency property
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
<RunParams>
|
<RunParams>
|
||||||
<local>
|
<local>
|
||||||
<FormatVersion Value="1"/>
|
<FormatVersion Value="1"/>
|
||||||
<CommandLineParams Value="--suite=TTestJSONDeStreamer.TestDateTimeFormat"/>
|
<CommandLineParams Value="--suite=TTestParser.TestObjectError"/>
|
||||||
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
|
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
|
||||||
</local>
|
</local>
|
||||||
</RunParams>
|
</RunParams>
|
||||||
|
@ -1584,7 +1584,7 @@ begin
|
|||||||
TestAsBoolean(J,True,False);
|
TestAsBoolean(J,True,False);
|
||||||
TestAsInteger(J,-1,False);
|
TestAsInteger(J,-1,False);
|
||||||
TestAsInt64(J,-1,False);
|
TestAsInt64(J,-1,False);
|
||||||
TestAsQWord(J,-1,True);
|
TestAsQWord(J,QWord(-1),True);
|
||||||
TestAsString(J,S);
|
TestAsString(J,S);
|
||||||
TestAsFloat(J,-1.0,False);
|
TestAsFloat(J,-1.0,False);
|
||||||
finally
|
finally
|
||||||
@ -1629,7 +1629,7 @@ begin
|
|||||||
TestAsBoolean(J,True,False);
|
TestAsBoolean(J,True,False);
|
||||||
TestAsInteger(J,-1,True);
|
TestAsInteger(J,-1,True);
|
||||||
TestAsInt64(J,-1,True);
|
TestAsInt64(J,-1,True);
|
||||||
TestAsQWord(J,-1,True);
|
TestAsQWord(J,QWord(-1),True);
|
||||||
TestAsString(J,S);
|
TestAsString(J,S);
|
||||||
TestAsFloat(J,-1.0,True);
|
TestAsFloat(J,-1.0,True);
|
||||||
finally
|
finally
|
||||||
|
@ -366,12 +366,8 @@ Var
|
|||||||
|
|
||||||
begin
|
begin
|
||||||
B:=TCompComponent.Create(Nil);
|
B:=TCompComponent.Create(Nil);
|
||||||
DeStream('{ "ExtendedProp" : 5.67 }',B);
|
DeStream('{ "CompProp" : 5.67 }',B);
|
||||||
{$ifdef CPUX86_64}
|
AssertEquals('Correct comp value',round(5.67),B.CompProp);
|
||||||
AssertEquals('Correct comp value',round(5.67),B.ExtendedProp);
|
|
||||||
{$else}
|
|
||||||
AssertEquals('Correct extended value',5.67,B.ExtendedProp);
|
|
||||||
{$endif}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TTestJSONDeStreamer.TestFloat5;
|
procedure TTestJSONDeStreamer.TestFloat5;
|
||||||
@ -876,12 +872,7 @@ procedure TTestJSONStreamer.TestWriteFloat4;
|
|||||||
begin
|
begin
|
||||||
StreamObject(TCompComponent.Create(Nil));
|
StreamObject(TCompComponent.Create(Nil));
|
||||||
AssertPropCount(1);
|
AssertPropCount(1);
|
||||||
// Extended is correct, propname is wrong
|
AssertProp('CompProp',5);
|
||||||
{$ifdef CPUX86_64}
|
|
||||||
AssertProp('ExtendedProp',TJSONFloat(5));
|
|
||||||
{$else}
|
|
||||||
AssertProp('ExtendedProp',4.56);
|
|
||||||
{$endif}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TTestJSONStreamer.TestWriteFloat5;
|
procedure TTestJSONStreamer.TestWriteFloat5;
|
||||||
|
Loading…
Reference in New Issue
Block a user