Forum Discussion
Hi richie
Thanks for your feedback. I've adapted the time as I didn't understood this measurement correctly.
Concering the fact if it really work or not is this:
As I have put the tokenizer in Auth manager, and the REST Request is fetching this token in it's request, I don't know the sequence of actions in a testsuite. How is it executed sequentially?
A request has an Endpoint and a resource and parameters, it has (in this case) a token that should be used.
so how is the TestSuite actually executed?
* TestSuite click --> execute all testcases in me
* ReadyAPI searches for the first testcase --> start testcase
* ReadyAPI finds a first teststep that is a Delay --> execute delay of (here ) 30 seconds
* ReadyAPI finds a second teststep that is a Rest Request --> look into the Rest Request for Endpoint and then look if you need a token --> Execute.
If this is the way how it goes, the delay has no use. I need a delay after the Rest Request has found the token to fetch, and delay the proces then.
So actually, to my understanding, that Delay has no use in my case.
Might ReadyAPI look in the teststep Rest Request at the token first before looking at the endpoint, then I should script something to delay the execution of the Rest Request in scripting or something like that.
So, yhé, now that I'm writing this I notice that I explained it wrongly. Sorry. I know that it works, because I see the countdown, but not for my case....
Actually I think I need to use EventHandlers for this but I have no clue about scripting....
Regards,
AAB
AAB , As i have understood, you need to wait till the desired condition gets satisfied, so in that case Delay won't help you need to write some logic(script) so that you can let your script wait till the till desired condition gets satisfied.
Let me know if you need help at coding part, will be happy to help 🙂
- AAB5 years agoRegular Contributor
That would be great if you could help me because indeed, I'm not a coder 😉
So yes, please give me a script for this. And where should I put it? in an assertion? On testcase level in a setup script?.....
Thanks in advance!
Regards, AboveAndBeyond
- HimanshuTayal5 years agoCommunity Hero
AAB : You can PM me with some details.
Like where your token is generating where it is getting stored how you are checking if is generated.
- richie5 years agoCommunity HeroHey HimanshuTayal,
If you manage to put some code together to extract the token value without executing the REST step, you might want to make the post sticky or i think theres a "handy stuff" section for cool stuff.
Ive seen lots of posts in the last year about doing this.
Just a suggestion fella,
Rich
Related Content
- 4 years ago
- 2 years ago
- 7 years ago
Recent Discussions
- 15 hours ago
- 17 days ago