Skip to main content

isEqualTo

Short summary

This assertion method checks if the current string stringToCheck is equal to expected. Processed strings must be in Windows-1252 or Windows-1251 encoding

Attention: All strings are handled as null-terminated byte streams

Parameters

NameTypeCommentKind
stringToCheckPOINTER TO BYTEcurrent string to checkinput
expectedPOINTER TO BYTEstringToCheck must be equal to expectedinput
ignoreCasesBOOLTRUE means ignore cases; FALSE means that cases must be equal tooinput
messageAssertMessagemessage if the assertion is falseinput
sbcsTypeTc2_Utilities.E_SBCSTypeused Single Byte Character Set (SBCS), is set in Tc2_Utilities.GLOBAL_SBCS_TABLEinput

Code

Declaration

METHOD isEqualTo
VAR_INPUT
(* current string to check *)
stringToCheck :POINTER TO BYTE;
(* ``stringToCheck`` must be equal to expected *)
expected :POINTER TO BYTE;
(* ``TRUE`` means ignore cases; ``FALSE`` means that cases must be equal too *)
ignoreCases :BOOL;
(* message if the assertion is false *)
message :AssertMessage;
(* used Single Byte Character Set (SBCS), is set in Tc2_Utilities.GLOBAL_SBCS_TABLE *)
sbcsType :Tc2_Utilities.E_SBCSType := Tc2_Utilities.E_SBCSType.eSBCS_WesternEuropean;
END_VAR