Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can LabVIEW Memory manager be run Headless for testing - Owned Types #25

Open
jkneer opened this issue Jul 8, 2024 · 4 comments
Open

Comments

@jkneer
Copy link
Contributor

jkneer commented Jul 8, 2024

The API is loaded using load_self(), which assumes that LabVIEW loads labview-interop when executing DLL calls from VIs.

With the advent of Owned Types this may not necessarily be True, i.e. for tests that need the LV memory manager, but do not require to be launched through LabVIEW.

Proposed solution:

  • Can we detect if we run the link feature standalone and if we do have a DLL path detection?

Now after having written this, I wonder if LV does actually support a headless operation of the memory manager, maybe with the LV Runtime?

@jkneer jkneer changed the title Bug? API loaded with load_self() - may be unavailable for Owned Types Can LabVIEW Memory manager be run Headless for testing - Owned Types Jul 8, 2024
@JamesMc86
Copy link
Contributor

I can dig deeper, but I'm pretty sure this isn't possible since we are linking to functions in the LabVIEW exe, which become available when loaded in that context. I don't believe there is a way to link to these through a separate library.

@jkneer
Copy link
Contributor Author

jkneer commented Jul 8, 2024

It would be nice to have this as it would make writing tests for all the functionality interfacing the memory manager much easier.

@JamesMc86
Copy link
Contributor

JamesMc86 commented Jul 8, 2024

Yep it would be easier. Right now though the way to test this is through the VI tester library in LabVIEW. There is a script in the justfile for this (https://github.com/WiresmithTech/Rust-LabVIEW-Interop/blob/main/justfile) which can give a sense of what is required. I need to tweak it to use a public VI tester runner.

You can try running through https://www.vipm.io/package/sas_workshops_lib_vitester_for_g_cli/ instead - should just need the capitalization in the command changing.

Alternatively you can run it through the VI tester UI as shown at https://github.com/vipm-io/vi-tester/wiki/UI-Overview

@JamesMc86
Copy link
Contributor

I had another thought around this, I'm not sure if this can work but maybe we can load the runtime into memory instead (LVRT.dll). The question is how easy is it to initialize and does it need to be initialized for the basic functions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants