How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript?
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript?
Hi there, I'm reaching out to you with small issue. The issue is mainly related with the importing the namespace com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in the Rhino Javascript test step.
When trying to import this namespace / class in the Rhino Javascript, I get below error alert -
'org.mozilla.javascript.EvaluatorException: missing ; before statement'
Can you please help me to successfully use OltuOAuth2ClientFacade class in the Rhino Javascript.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @VivekJainYja ,
Could you please send your script and a screenshot demonstrating where you use this script?
You may also find some useful instructions by this link:
https://support.smartbear.com/readyapi/docs/projects/requests/auth/types/oauth2/automate/sample.html
Olga Terentieva
SmartBear Assistant Community Manager
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Olga,
Thank you for your response. A link mentioned in your response is not so helpful in my scenario where I'm using Script Language as Rhino Javascript, Not Groovy.
I'm trying to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino JavaScript.
Let's say in Groovy Script, we already have a syntax to use this namespace as
import com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade;
Is there any similar way to use this namespace in the Rhino Javascipt language type?
Please refer attached snap shots.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @VivekJainYja ,
Groovy is much more popular because it allows better access to some objects. I suggest that you consider using Groovy.
I've also googled the question a bit and found that Rhino has the import statement. Perhaps, the syntax is different as compared to Groovy. Here is the link to the documentation:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import
Olga Terentieva
SmartBear Assistant Community Manager
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
