oh, I see ! I thought these functions were actually nested, and my adding the "end" markers would only affect syntac, not semantics.
Now I understand that I actually misunderstood how things work, so I acceidentally changed the semantics.
All is working fine now. Thanks for your prompt help !
I have just discovered this unit testing framework. Thanks for sharing this !
I'm trying to write a simple test suite, with multiple nested test functions in a single .m file. The MATLAB docs suggest that all nested functions need to terminate with "end".
Modifying your "testFliplr.m" file to insert these "end" keywords makes runtests no longer recognize and run the tests from this file.
Am I missing something, or is this a bug in the harness' test parser ?
I'm using MATLAB R2012a.
Asan, this is a unit testing framework to help ensure your MATLAB programs have been written correctly and to prevent changes from introducing bugs. There is now a unit test framework included in MATLAB, and you may be interested in the following blog post describing how someone can use such a framework to ensure the quality of science & engineering:
I tried to understand 'MATLAB xUnit Test Framework' from description but unfortunately the most part I couldn't understand, can tell me is useful for what in more simple way, sorry I'm new user of MATLAB
In R2013a, a curious glitch has emerged in the behavior of the documentation. When I type 'doc', go to the home page, and click on 'Supplemental Software', I get the documentation for this package (and some others). However, the display flickers. MATLAB Support uncovered the source of the problem: the line
<meta http-equiv="REFRESH" content="0;url=xunit_product_page.html">
in the file index.html.
The fix was to delete index.html and replace it with a copy of xunit_product_page.html, renamed to index.html.
Keith - On my Mac, MATLAB xUnit passes 150 of the 151 test cases in its own test suite. (The one failure seems to be a bad test case.) Use the contact form on my author page (http://www.mathworks.com/matlabcentral/fileexchange/authors/22204) to send me more details about the problem you are experiencing.
Hey, I understand that xUnit is superceded by the official unit test framework in 2013b, but I have a lot of test functions set up for xUnit. When I try to run them in 2013b, even with xUnit put at the top of the path, it doesn't work. Is there a way to either (a) get my old functions to work, or (b) automatically convert my xUnit tests to the new system?