SIL Testing and Polyspace
2 visualizaciones (últimos 30 días)
Hi, I actually work as software tester and my job consist in verify the Embedded C code generated from a Simulink model using SIL approach. Basically I have a model, a plant, that is a test harness, and the SIL block. What I have to do is implement test cases to verify part of the code, this could be an entire function or part of it. Tests should cover function behaviour completely, if possible, so each path should be tested, like a normal unit test. At the moment the entire process takes me a lot of time, most of which is spent for settings, the test harness is not generated automatically for example. So I'd like to know, is it be possible to perform all this actions automatically? I mean, does exist a tool which takes a function, or an entire component, and generate all the test cases that are needed. I was looking at Simulink Design Verifier features, and it seems to be just the Tool, I'd like to have a confirm here anyway! However, the problem is my Matlab and Simulink licence does not include Simulink Design Verifier, so it would be nice to use something else, if possible. Talking about Tools, could Polyspace be an alternative to the SIL testing? I know the first one is used for static analysis, whilst with SIL approach we have dinamic analysis, on the other hand, int the following article http://www.mathworks.com/products/polyspace/static-analysis-notes/better-testing-with-static-analysis.html appear that the abstract interpretation technique Polyspace uses would give completeness to the test, in term of static and dinamic behaviour. Can someone help with this matter?
Lucas Lebert el 6 de Dic. de 2016
The comment from Satiskumar is correct. The Code Prover detects runtime errors and the Bug Finder detects bugs in the code. The functionality of the code is not tested. For example Polyspace does not compare the expected output with the real output. If you want to generate test cases, you indeed need the Simulink Design Verifier.
Jay Abraham el 12 de Abr. de 2017
You can certainly use the Simulink Design Verifier tool to automatically generate test inputs from your Simulink and Stateflow model. The Simulink Design Verifier tool generates test from test objectives that you can specify or it can automatically generate tests to satisfy coverage objectives for block execution, condition, decision, and MCDC. See this link in the documentation page for more information (you need a MathWorks account to access)
The Polyspace products are static code analysis tools. They analyze and verify C/C++ code to find bugs or to prove that the code is free of critical run-time errors. The Polyspace products do not perform testing activities on the code, however they can find dead code. Dead code would indicate untestable elements in your code. You can learn more about dead code at the link below.
Jay Abraham el 10 de Sept. de 2017
The Simulink Test tool is intended to help you perform SIL testing. You can learn more about the product at the links below.
Overview of Simulink Test - https://www.mathworks.com/products/simulink-test.html
Documentation explaining how to do SIL testing - https://www.mathworks.com/help/sltest/ug/silpil-verification-for-a-subsystem.html