07-27-2011 12:07 PM
Hello Everyone,
I was trying to create a unit test for a VI using the unit test framework (evaluation version) to try out this tool. I have two questions regarding that.
1. Several sub-VIs are called by this VI. I wanted to create a unit test for each of these sub-VIs so that I could test each of them separately. But UTF provided me with the option to create a unit test for the main VI alone. The main VI is huge and getting 100% code coverage is going to be a challenging task. Is there a way by which I can create unit tests for the individual sub-VIs?
2. When I tried to create the unit test for the main VI, I got an error saying: Cannot create a test from this VI. Contains the following duplicate control labels. This is because the same indicators are being used in different cases within a case structure.
Is there anyway to resolve this issue?
Thanks
07-27-2011 01:18 PM
How can the same indicator be used in different cases of a case structure?
That shouldn't be possible. Normal you would use local variables or property nodes to write to a indicator from multiple places. ( Not that is it a good design to have multiple places where a write to a indicator happens. )
07-27-2011 01:27 PM
If I understand what the problem is you have to controls or indicators that have the same name. To fix this you need to give them unique names. If they need to say the same thing on the user interface then you can use the caption and change the name on that so they both have the same name.
01-27-2014 10:27 PM
In my program i'm using property nodes for diffrnt indicators and controls. I'm also getting the same error while executing unit test. (The VI contains following duplicate control labels)