[r917]: / branches / develop / mqttsparkplug / mqttsparkplug-unittest / Device / Plc Logic / mqttsparkplug / PRG_UNIT_TEST / Tests / FB_WSTRINGBuilder_TestSuite / Test_Find / svnobj  Maximize  Restore  History

Download this file

17 lines (14 with data), 2.5 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
IF counit.TEST_ORDERED('Test_Find') THEN
    GVL.Test_Find := GVL.Test_Find +1;
    
    _fbWSTRINGBuilder.Append(wsText1);    
    iPos := _fbWSTRINGBuilder.Find(wsFind);
    iExpected := WFIND(wsText1,wsFind);
    AssertEquals_INT( Expected := iExpected,
                      Actual :=  iPos, 
    wsText1 : WSTRING(160):= ("Greetings in various languages: Hello world, 
 
, 
");
    wsFind : WSTRING := "languages";
    iPos : INT;
    iExpected : INT;
    _fbWSTRINGBuilder : Sparkplug.FB_WSTRINGBuilder;