运行测试在Matlab2015b中工作,但在2013b中不工作

运行测试在Matlab2015b中工作,但在2013b中不工作,matlab,testing,Matlab,Testing,我尝试了runtests函数示例 在Matlab2015b中,一切都能完美工作。但在Matlab2013b中,我得到以下错误 >> runtests Error using runtests (line 41) Not enough input arguments. 如果我解释一下其中一个m文件 >> runtests('typeTest.m') 我明白了 有人能告诉我我做错了什么吗 在这些版本之间,runtests函数发生了更改。0输入语法似乎是在R2014b中首次

我尝试了runtests函数示例 在Matlab2015b中,一切都能完美工作。但在Matlab2013b中,我得到以下错误

>> runtests
Error using runtests (line 41)
Not enough input arguments.
如果我解释一下其中一个m文件

>> runtests('typeTest.m')
我明白了


有人能告诉我我做错了什么吗

在这些版本之间,runtests函数发生了更改。0输入语法似乎是在R2014b中首次为该函数记录的

请参阅R2013b版本的runtests文档,以确定该函数在该版本中的工作方式:

此外,请查看发行说明以了解对功能所做的更改:

Error using matlab.unittest.TestSuite.fromFile (line 94)
"C:\Users\u16h62\Documents\MATLAB\Example\typeTest.m" is not a valid test    file.
 Error in runtests>createSuite (line 60)
 suite = TestSuite.fromFile(file);
 Error in runtests>@(test)createSuite(test,parser.Results.Recursively) (line   41)
suites = cellfun(@(test)createSuite(test, parser.Results.Recursively), ...
Error in runtests (line 41)
suites = cellfun(@(test)createSuite(test, parser.Results.Recursively), ...