File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -300,11 +300,21 @@ function testSaveLoadSession(testCase)
300300
301301 % Find the animal view
302302 view = cview .ActiveView ;
303+
304+ import matlab .unittest .constraints .Eventually
305+ import matlab .unittest .constraints .Matches
303306
304307 % Verify name in view matches
305308 diag = " Expected updated name to display in the view after loading." ;
306- actVal = view .NameField .Value ;
307- testCase .verifyMatches(actVal , newName , diag );
309+ testCase .verifyThat(...
310+ @()string(view .NameField .Value ),...
311+ Eventually(Matches(newName ), " WithTimeoutOf" , 5 ), ...
312+ diag );
313+
314+ % Verify name in view matches
315+ % diag = "Expected updated name to display in the view after loading.";
316+ % actVal = view.NameField.Value;
317+ % testCase.verifyMatches(actVal, newName, diag);
308318
309319 end % function
310320
You can’t perform that action at this time.
0 commit comments