Skip to main content

valueIsInRangeOf

Short summary​

This assertion method checks if the current value is inside a limit

Attention: limits are included: valueIsInRangeOf(date#1970-01-01, date#1970-01-01, date#1970-01-01) is a true assertion

Parameters​

NameTypeCommentKind
lowerLimitDATElower limit for the current valueinput
currentValueDATEcurrent value to checkinput
upperLimitDATEupper limit for the current valueinput
messageAssertMessagemessage if the assertion is falseinput

Code​

Declaration​

METHOD valueIsInRangeOf
VAR_INPUT
(* lower limit for the current value *)
lowerLimit :DATE;
(* current value to check *)
currentValue :DATE;
(* upper limit for the current value *)
upperLimit :DATE;
(* message if the assertion is false *)
message :AssertMessage;
END_VAR