cancel
Showing results for 
Search instead for 
Did you mean: 

Executing a Project from Azure DevOps resets Project Variables

SOLVED
Highlighted
New Contributor

Executing a Project from Azure DevOps resets Project Variables

Hello SmartBear Community,

 

My current project is testing a shopping cart.

 

Therefore i created a new TestComplete Project Suite and added one Project.

The flow is as following - one ore more KeyWord Tests each:

 

  • - Open the Browser and Navigate to the User Selection for Edition and License Amount
  • - Select a Edition and enter a RNG Amount of Licenses
  • - Put the Amount of Licenses and the calculated Price each into a String Variable ("Transfer Variable" from one page to the next)
  • - Compare the Amount of Licenses and the calculated Price from the Variables with the ones shown in the Shopping Cart

Whilst this flow works flawless on my local System when i start the Project / Project Suite, starting it via Azure DevOps DISCARDS the Project Variables between the KeyWord Test since the Assemblies are not loaded as whole project but one KeyWord Test after another. I logged each step so i can 100% confirm the variables are discarded after the KeyWord Test is done.

 

That is my first time working with Project Variables in DevOps, all other DevOps Tests work flawless so far.

 

Did anyone already experience that same challenge and how did you fix it?

 

Update:

Using ProjectSuite Variables instead of Project Variables bears the same issue.

 

Thank you very much in Advance & Best Regards

Michael

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Staff

Re: Executing a Project from Azure DevOps resets Project Variables

I just tried a similar workflow using persistent project level variables to assign an object property value in the first keyword test, and verified that value via a property checkpoint asserting against that persistent project level variable in a separate keyword test (all executed via Azure Devops) and my tests worked fine. 

 

can you post how you are storing/creating these variables, what your script looks like, what the error messages are?

Best,
Justin Kim

View solution in original post

5 REPLIES 5
Highlighted
Community Manager

Re: Executing a Project from Azure DevOps resets Project Variables

Thank you for creating a topic! Let's ask the Community for help here.

 

@tristaanogre  @AlexKaras @BenoitB @cunderw do you have any suggestions on this one?🙂


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
Highlighted
Community Hero

Re: Executing a Project from Azure DevOps resets Project Variables

Hi Michael,

 

I did not use TestComplete with Azure DevOps yet, so I barely can be of much help here...

 

since the Assemblies are not loaded as whole project but one KeyWord Test after another.

I am not sure I got what assemblies you are talking about. Could you clarify, please?

Also, could you describe how your tests are executed? All in one go from one test project as test items or tests are triggered by more than one command with only one test been executed?

If the latter, then my guess is that DevOps might re-deploy TestComplete project before each execution and this obviously discards changes made to the Project Variables (regardless of permanent or temporary type) because the changes are not preserved to the original location the project is deployed from.

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================
Highlighted
Staff

Re: Executing a Project from Azure DevOps resets Project Variables

I just tried a similar workflow using persistent project level variables to assign an object property value in the first keyword test, and verified that value via a property checkpoint asserting against that persistent project level variable in a separate keyword test (all executed via Azure Devops) and my tests worked fine. 

 

can you post how you are storing/creating these variables, what your script looks like, what the error messages are?

Best,
Justin Kim

View solution in original post

Highlighted
Community Manager

Re: Executing a Project from Azure DevOps resets Project Variables

Thank you for trying to help here Alex, Justin!

 

@Kazuka did you find the cause of the issue? Please provide the details the Community is asking so that we could keep the investigation going here. Alternatively, you can reach out to the Support Team and see what they find.


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
New Contributor

Re: Executing a Project from Azure DevOps resets Project Variables

Hi & thank you all for your help so far!

 

I just realized i used Temporary Variables instead of Persistent Variables, as i said my first time working with these, i will try this suggestion from @hkim5, i am positive this will fix the issue!

 

Thank you very much & have a nice day!

New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors