caraya icon indicating copy to clipboard operation
caraya copied to clipboard

Open Tests Associated with Current VI

Open jacobson3 opened this issue 4 years ago • 3 comments

This is more of an "idea exchange" type post with a small PoC. I thought that it might be interesting to be able to work on a VI for your application and easily navigate to the the associated tests for that VI. The concept would be that you are working on "Parse Message Data.vi" and by just invoking a QD shortcut, the VI used for testing that VI pops up.

Attached is a super basic proof of concept built in LabVIEW 2019. If the VI is put in the QD plugins folder you can use the Ctrl+A QD shortcut to open the first "Test VI" found where a test VI is determined by being a VI in your active project which links to both the Define Test Caraya VI and the VI which makes the QD call.

Most of the functionality needed to do this already exists in "Test Runner.Project.lvclass:onTestDiscovery.vi". The attached code is mostly just inlines existing functions so everything is on one VI and to avoid scoping issues.

QD.zip

jacobson3 avatar May 21 '20 22:05 jacobson3

Hi @jacobson3. This is a fantastic idea and a very valid/common use case! It gets my vote.

jimkring avatar May 22 '20 18:05 jimkring

Thanks Jim. I think the biggest open question would be how to handle instances where multiple tests call the VI in question. If one test is found I think you can just open the VI directly but if multiple tests are found, a dialog similar to the choose class implementation preview should come up.

jacobson3 avatar May 22 '20 19:05 jacobson3

Great point! Yes, a small dialog Would probably make sense I. The case of multiple tests

On Fri, May 22, 2020 at 12:33 PM Jacobson [email protected] wrote:

Thanks Jim. I think the biggest open question would be how to handle instances where multiple tests call the VI in question. If one test is found I think you can just open the VI directly but if multiple tests are found, a dialog similar to the choose class implementation preview should come up.

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/JKISoftware/Caraya/issues/90#issuecomment-632876594, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC5D6A4Y63H7P5LAZB37JDRS3HPPANCNFSM4NHHHGAQ .

-- Jim Sent from my mobile.

jimkring avatar May 22 '20 19:05 jimkring