-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Edit environment variables programmatically in Unit Tests #3218
Description
What is your question?
A clear and concise description of what you are wanting to ask. Ex. I'm always frustrated when [...]
Environment variable and template tags are very powerful in Collections, but I don't find any document about their usage in Unit testing. Is it possible to use them in Unit testing?
In addition, I'd like to get some data from external apis to automate some testing scenarios, do Unit testing support it?
What is the context?
If applicable, describe the context in which you are asking the question. Ex. I am trying to do x with y [...]
To support table-driven testing, I'd like to define a static list of data before executing tests. In some special cases, these data can be got from external apis which I'd like to call to get that data to use, therefore, I need to call external api in unit testing.