Browse Source

* Adapted test to change to TExtRttiData

git-svn-id: branches/joost/classattributes@24655 -
joost 12 years ago
parent
commit
c17f509d41
1 changed files with 5 additions and 4 deletions
  1. 5 4
      tests/test/tclassattribute9.pp

+ 5 - 4
tests/test/tclassattribute9.pp

@@ -7,6 +7,7 @@ uses
 
 
 type
 type
   { tmyt }
   { tmyt }
+  // TCustomAttribute without constructor
   tmyt = class(TCustomAttribute);
   tmyt = class(TCustomAttribute);
 
 
 type
 type
@@ -15,15 +16,15 @@ type
   end;
   end;
 
 
 var
 var
-  td: PTypeData;
+  rtd: PExtRTTIData;
   AClassAttribute: TCustomAttribute;
   AClassAttribute: TCustomAttribute;
 
 
 begin
 begin
-  td := GetTypeData(TMyObject.ClassInfo);
-  if td^.AttributeCount<>1 then
+  rtd := GetExtRTTIData(TMyObject.ClassInfo);
+  if rtd^.AttributeData^.AttributeCount<>1 then
     halt(1);
     halt(1);
 
 
-  AClassAttribute := GetClassAttribute(td,0) as TCustomAttribute;
+  AClassAttribute := GetClassAttribute(rtd,0) as TCustomAttribute;
   if AClassAttribute = nil then
   if AClassAttribute = nil then
     halt(2);
     halt(2);
   writeln('ok');
   writeln('ok');