cancel
Showing results for 
Search instead for 
Did you mean: 

How to use Log message as variable in Keyword test?

SOLVED
Highlighted
New Contributor

How to use Log message as variable in Keyword test?

Hi all,

 

Well i am trying to get the log results into the varibles to perform my keyword test, as these log results are form the script which is generating the random numbers form a csv file and i want to use these number for my keyword test to perform an automation test. it would be great if someone will guide me.

 

Thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Leader

Re: How to use Log message as variable in Keyword test?

There is an good article on how to use Variables

 

https://support.smartbear.com/testcomplete/docs/working-with/managing-projects/common/variables-page...

 

Please let me know in case you need anything else.

View solution in original post

6 REPLIES 6
Highlighted
Community Hero

Re: How to use Log message as variable in Keyword test?

Hi,

 

I am not sure that I got your description...

Can you provide an example, please?

 

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
New Contributor

Re: How to use Log message as variable in Keyword test?

Hi @AlexKaras ,

 

Thank you for writing back, well i am performing a test where i need random numbers from csv file to execute the test. I am already done with the keyword test and the script to get the random numbers but as the script is giving these random numbers in result log so i need to use these result logs as variables to perform the keyword test. I would like to know if it is possible to make the result logs as variables to perform the test or it cannot be done.

 

looking to hear from you.

 

Highlighted
Community Hero

Re: How to use Log message as variable in Keyword test?

Hi,

 

While you should be able to write a code that parses log file and extracts the number from it, but why not to use the (temporary) Project Variable and use it to keep and transfer the needed value between tests?

 

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
New Contributor

Re: How to use Log message as variable in Keyword test?

Hello again,

 

It would be great if you would let me know about how to use the temporary project variable.

 

 

Best regards

Highlighted
Community Leader

Re: How to use Log message as variable in Keyword test?

There is an good article on how to use Variables

 

https://support.smartbear.com/testcomplete/docs/working-with/managing-projects/common/variables-page...

 

Please let me know in case you need anything else.

View solution in original post

Highlighted
Community Manager

Re: How to use Log message as variable in Keyword test?

Thank you, Community! Awesome job here.

 

@sukhsagar was the article provided helpful to you?


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors