poster
2019-12-10, 20:48
现有的MATLAB单元测试框架是什么,它们如何比较?我应该如何为我们的项目选择一个?他们的优缺点是什么?
回答:
我认为最受欢迎的MATLAB 框架 (http://www.mathworks.com/matlabcentral/fileexchange/22846-matlab-xunit-test-framework)是File Exchange上提供的xUnit Test Framework (http://www.mathworks.com/matlabcentral/fileexchange/22846-matlab-xunit-test-framework) 。非常灵活并且有据可查。
此处 (http://en.wikipedia.org/wiki/List_of_unit_testing_frameworks#MATLAB)和此处 (http://mlunit.dohmke.de/Unit_Testing_With_Matlab)列出了 (http://en.wikipedia.org/wiki/List_of_unit_testing_frameworks#MATLAB)其他一些单元测试工具。
另一个非常有趣的文件交换提交文件是Doctest (http://www.mathworks.com/matlabcentral/fileexchange/28862-doctest-embed-testable-examples-in-your-functions-help-comments) 。但是,它并不完全是单元测试框架,它的工作方式类似于Python中的doctest 。我还没有尝试过,但是对于嵌入功能帮助中的简单测试而言,它看起来很有希望。
更多&回答... (https://stackoverflow.com/questions/3992295)
回答:
我认为最受欢迎的MATLAB 框架 (http://www.mathworks.com/matlabcentral/fileexchange/22846-matlab-xunit-test-framework)是File Exchange上提供的xUnit Test Framework (http://www.mathworks.com/matlabcentral/fileexchange/22846-matlab-xunit-test-framework) 。非常灵活并且有据可查。
此处 (http://en.wikipedia.org/wiki/List_of_unit_testing_frameworks#MATLAB)和此处 (http://mlunit.dohmke.de/Unit_Testing_With_Matlab)列出了 (http://en.wikipedia.org/wiki/List_of_unit_testing_frameworks#MATLAB)其他一些单元测试工具。
另一个非常有趣的文件交换提交文件是Doctest (http://www.mathworks.com/matlabcentral/fileexchange/28862-doctest-embed-testable-examples-in-your-functions-help-comments) 。但是,它并不完全是单元测试框架,它的工作方式类似于Python中的doctest 。我还没有尝试过,但是对于嵌入功能帮助中的简单测试而言,它看起来很有希望。
更多&回答... (https://stackoverflow.com/questions/3992295)