Your Privacy
We use cookies to give you a better experience in Alchemy Help Center
You can learn more about what kind of cookies we use, why, and how from our Privacy Policy. Because we respect your right to privacy, you can choose not to allow some types of cookies. Click on the different category headings in our cookie banner to change our default settings. However, blocking some types of cookies may impact your experience of the site and the services we are able to offer. For more details, check out our Privacy Policy link below.
View Privacy Policy
Strictly Necessary Cookies
These cookies are necessary for the website to function and cannot be switched off in our systems, but do not store any person information. They are usually set in response to your actions that triggers a request for services, such as setting your privacy preferences, logging in or filling forms. You can change your browser settings to alert you about these cookies, but some parts of the Website may not work.
View Cookies
I have defined a global variable in a test, let's call it Test1. Since it's a global variable, it should be accessible across different tests. However, I'm unable to see this variable in the context variables section of other tests. Can anyone explain how I can use this global variable in other tests and functions within the suite?
0 Votes
TheBugScout posted 2 months ago Best Answer
The global variable you created or defined in one test ( let's say Test1 ) will be visible in the context variable section of that specific test, but not in the context variable section of other tests. However, since it is a global variable, you can still use it in other tests and functions.
Here is a workaround to use the global variable in another test:
1. Copy the global variable from the context variable section of the test where it is defined using the copy icon in front of the name of that global variable.
2. Go to the other test or function where you want to use it and paste it into the required step where you want to use it.
0 Votes
1 Comments
TheBugScout posted 2 months ago Answer
The global variable you created or defined in one test ( let's say Test1 ) will be visible in the context variable section of that specific test, but not in the context variable section of other tests. However, since it is a global variable, you can still use it in other tests and functions.
Here is a workaround to use the global variable in another test:
1. Copy the global variable from the context variable section of the test where it is defined using the copy icon in front of the name of that global variable.
2. Go to the other test or function where you want to use it and paste it into the required step where you want to use it.
0 Votes
Login or Sign up to post a comment