diff --git a/test/+wt/+test/FileSelector.m b/test/+wt/+test/FileSelector.m index 64aa207..e6b0225 100644 --- a/test/+wt/+test/FileSelector.m +++ b/test/+wt/+test/FileSelector.m @@ -189,6 +189,10 @@ function testButtonLabel(testCase) % line. function testButton(testCase) + % Running in desktop mode? + testCase.assumeEqual(exist('desktop', 'file'), 6, 'Cannot find function ''desktop.m''.') + testCase.assumeTrue(desktop('-inuse'), 'MATLAB must run in desktop mode in order to complete current test.') + % Get the button control buttonControl = testCase.Widget.ButtonControl; diff --git a/test/+wt/+test/PasswordField.m b/test/+wt/+test/PasswordField.m index a252852..f60345e 100644 --- a/test/+wt/+test/PasswordField.m +++ b/test/+wt/+test/PasswordField.m @@ -42,6 +42,10 @@ function testValue(testCase) function testTyping(testCase) + % Running in desktop mode? + testCase.assumeEqual(exist('desktop', 'file'), 6, 'Cannot find function ''desktop.m''.') + testCase.assumeTrue(desktop('-inuse'), 'MATLAB must run in desktop mode in order to complete current test.') + % Get the password field passField = testCase.Widget.PasswordControl; newValue = "AbC435!";