Add more unit tests for Ada function list

for enhancement:
8ab9b99b73
pull/15098/head
Don Ho 2024-05-05 23:28:41 +02:00
parent 8ab9b99b73
commit 6281227d84
2 changed files with 38 additions and 4 deletions

View File

@ -1 +1 @@
{"leaves":["BiSeqOut"],"root":"unitTest"}
{"leaves":["BiSeqOut","Get_Idle","Get_State","Update","Int32_To_Byte_Array","Int8_To_U8","Int32toInt8TwosComplement (value : Vt.Int32)","AproxU8 (n : Vt.U8; x : Vt.U8)","Read_I32 (Register : Vt.Address_Range)"],"root":"unitTest"}

View File

@ -34,10 +34,44 @@ begin
end BiSeqOut;
-- Result of Execution
-- (The only output is a binary file named NAMEFILE.TXT)
function Get_Idle
return Boolean;
function Get_State
return Vt.State;
procedure Update;
function Int32_To_Byte_Array is
new Unchecked_Conversion (Source => Vt.Int32, Target => Vt.Byte_Array);
function Int8_To_U8 is new Unchecked_Conversion
(Source => Vt.Int8, Target => Vt.U8);
function Int32toInt8TwosComplement (value : Vt.Int32) return Vt.Int8 is
begin
-- body
end Int32toInt8TwosComplement;
function AproxU8 (n : Vt.U8; x : Vt.U8) return Boolean is
eq : Boolean := False;
begin
-- code
return eq;
end AproxU8;
function Read_I32 (Register : Vt.Address_Range) return Vt.Int_32 is
Data : Vt.Int_32;
begin
-- code
return Data;
end Read_ I32;