aggregate coverage data for multiple unit test models
2 次查看(过去 30 天)
显示 更早的评论
hello all,
I am trying to aggregate the coverage data for a referenced model which is shared in two (or more) unit test models. I was wondering how to aggregate the coverage data when running both unit tests.
I have tried the following code:
open_system('unit_test_1.slx');
% modify the data dictionary used by the unit test model and referenced model
cv1=cvsim(bdroot);
open_system('unit_test_2.slx');
% modify the data dictionary used by the unit test model and referenced model
cv2=cvsim(bdroot);
cv_total=cv1+cv2;
cvhtml('test.html',cv_total);
For both unit test models coverage is enabled for the referenced models, thus recording the coverage for the shared reference model. However this approach doesn't work because the concatenation of the cvdata object is failing.
Anyone has a clue how to solve this?
thanks in advance, Han Geerligs
1 个评论
Pat Canny
2018-11-9
Hi Han. What do you mean by "concatenation of the cvdata object is failing"? Are you getting an error? Also, what do you mean by "modify the data dictionary"? Are you changing the model between simulations?
采纳的回答
Pat Canny
2018-11-12
Hi Han,
That is correct. When trying to use the + operator on cvdata from different models, you will get an error.
I recommend contacting MathWorks Support . They might be able to help you with your workflow, though there is no workaround for combining coverage results from different models.
0 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Manage Coverage Data 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!