cancel
Showing results for 
Search instead for 
Did you mean: 

How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript?

New Contributor

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.

 

4 REPLIES 4
Moderator

Re: How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript

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

New Contributor

Re: How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript

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.

Moderator

Re: How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript

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

New Contributor

Re: How to use com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2ClientFacade in Rhino Javascript

Thanks for your response. However, solution provided could not help me as I'm trying to import auth class or namespace not module. For reference, I've again attached the snap shot.

 

Could you please keep this case open until resolved.

New Here?
Join us and watch the welcome video:
6 / 7 API Testing Mistakes Video
Top Kudoed Authors