1
0
mirror of synced 2024-11-12 22:39:17 +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.