1
0
mirror of synced 2024-11-14 15:03:51 +00:00
x2utils/UnitTests/Units/XMLDataBindingUtilsTest.pas

40 lines
675 B
ObjectPascal
Raw Normal View History

unit XMLDataBindingUtilsTest;
interface
uses
TestFramework;
type
TXMLDataBindingUtilsTest = class(TTestCase)
published
procedure TestIsValidXMLChar;
procedure TestGetValidXMLText;
end;
implementation
uses
XMLDataBindingUtils;
{ TXMLDataBindingUtilsTest }
procedure TXMLDataBindingUtilsTest.TestIsValidXMLChar;
begin
CheckTrue(IsValidXMLChar('A'));
CheckTrue(IsValidXMLChar('<27>'));
CheckFalse(IsValidXMLChar(#$1A));
end;
procedure TXMLDataBindingUtilsTest.TestGetValidXMLText;
begin
CheckEquals('AB', GetValidXMLText('AB'));
end;
initialization
RegisterTest(TXMLDataBindingUtilsTest.Suite);
end.