How to get var from base workspace in test sequence
Mostra commenti meno recenti
How to get var from base workspace in test sequence
6 Commenti
Rik
il 20 Ago 2024
I would never advise the use of evalin, especially not in a tester.
What are you actually trying to achieve? The answer below answers your question, but I expect you should be asking a different question.
(also, if the answer solves your question, you should click the 'accept answer' button)
浩 程
il 20 Ago 2024
浩 程
il 20 Ago 2024
浩 程
il 20 Ago 2024
"I want to use code to iterate a variable in a test sequence, which requires getting the change value from the workspace."
Pass it as an argument.
The approach you are attempting has a very strong smell to it: https://en.wikipedia.org/wiki/Code_smell
Rik
il 20 Ago 2024
Why don't you supply the list of test variables in a cell array?
Making your test cases static helps keeping your tests stable. Without a consistent test, it is not possible to have a good regression test.
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Inputs in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
