Contributions
Re: Hi Team,Can we test GraphQL request responses in SOAPUI ?
Hi, I am trying to find out how I can send a GraphQL request using SoapUI. I am able to do it in Postman but when I try it in SoapUI I get{"errors":[{"message":"Must provide query string."}]}. I have added the Content-Type header asapplication/graphql. I want to use SoapUI because Postman doesn't seem to support creating more automated test scripts with property transfers and assertions the way SoapUI does. I am just wondering why you think using SoapUI would be overkill? You may well be right but just wondering why you think this. Where would you use the Open Source Javascript library you mention if you are a tester wanting to test this externally? Thanks.3.8KViews0likes1CommentExtracting value from requestBody and using it in mockResponse
Hi, I am using Service V to create a mock response and I want to extract data from the json request body and use it in the response. The following is the json request body .. { "employName":"Pat McGraff", "companyId":"80966", "contactDetails":{ "emailAddress":"patmcgraff@gmail.com", "phoneNumber":"8427306667" } } I basically want to just use this same block in my mock response with additional data e.g. the response body would be { "employName":"Pat McGraff", "companyId":"80966", "contactDetails":{ "emailAddress":"patmcgraff@gmail.com", "phoneNumber":"8427306667" } }, "company":"company123", "location":"India", "client":"client123", "team":"BIG" } Is there a way I can do this using the context and requestContext in Service V in the scripting dispatch method? Many thanks.6 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.5KViews0likes1CommentRe: soapui-maven-plugin-5.3.0 does not work
I am getting the same error. I have added the soapui-maven-plugin-5.3.0.jar to my plugin SoapUI plugins repository. And also added the dependency below to POM file but I get the same error. <dependency> <groupId>com.jgoodies</groupId> <artifactId>forms</artifactId> <version>1.0.7</version> </dependency>13KViews0likes0CommentsRe: Basic WS security date used in created
Sorry Rao, I should clarify I did actually have those dates hardcoded in the request, so SoapUI does populate it with a dateTime stamp that is current, but I see that I can generate the password digest and nonce using a groovy script with a created date that is months in the past and paste this into the request in the Projects tab of SoapUI so that it isn't inadvertantly applying the security headers, and the request will still not fail authentication. Thanks.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.3KViews0likes0CommentsBasic WS security date used in created
Hi, I just has a question regarding the Basic WS security standard, specifically the date used to perform the hashing. Looking at some requests that I have submitted from SoapUI Pro using the BASIC WS security setting I can see that the date/Time used in the created element is not current. It is from a couple of months ago. Does this algorithm just take any date as long as it is in the correct format i.e. it doesn't have to be current or within the last hour? e.g. <wsse:Username>username</wsse:Username> <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordDigest">DDgOjpM5ibHBkQHZ571X5CEcs+I=</wsse:Password> <wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">vUx2pPOw2vCPWBqqrvrC0Q==</wsse:Nonce> <wsu:Created>2017-03-14T14:38:24.957Z</wsu:Created> Thanks.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.4KViews0likes3CommentsHashing password for outgoing WS-Security header parameters in REST web service request
Hi, We are developing a REST web service based on an existing SOAP service that uses Outgoing WS-security authentication. We want to add the nonce and password digest to the REST request as header parameters. I am using SoapUI NG to create my test cases. I can't see a way of applying these from the WS-Config like you can in a Soap request so I want to create a Groovy script to generate these. My code below doesn't work, due to the line where it creates the hashedPW. import java.security.* String password = "DUMMYPW" created = "2017-02-27T16:28:49Z" nonce = "368664078" HashedPassword = MessageDigest.getInstance("SHA-1").digest(password.getBytes("UTF-8")).encodeBase64().toString() PasswordDigest = MessageDigest.getInstance("SHA-1").digest((nonce+created+HashedPassword).getBytes("UTF- 8")).encodeBase64().toString() EncodedNonce = nonce.getBytes("UTF-8").encodeBase64() log.info "PasswordDigest is " +PasswordDigest log.info "Encoded Nonce is " +EncodedNonce I have the equivalent code in Python which when I apply the values to the REST request result in successful authentication. So basically I want to know what the groovy equivalent to this Python code would be .. hashedpassword = sha.new(password).digest() This causes the password string 'Password1*' to be hashed as ±w”=¶witØÿÒꀣñµ¨¥. Any help would be greatly appreciated.1.3KViews0likes0CommentsNot able to run ReadyAPI tests from Jenkins due to error : No valid SoapUI NG license exists.
Hi, I am trying to run some Ready API Maven tests from Jenkins but I am getting the below errors in the Jenkins console log. No valid SoapUI NG license exists. Please enter absolute path of the license file (.zip or .key): I have searched this error online and one of the suggestions for a common cause was "you are not running Jenkins with the same user account you activated the SoapUI NG license with. " (http://readyapi.smartbear.com/about/licenses/troubleshooting/jenkins) I am not able to check what user I am running Jenkins with as I don't have admin privileges, but I assume it would have to be my user as I installed it. I am running all this all on my local machine so Jenkins is installed on the same laptop as Ready API which has an active license. (The plan is to have this set up on a VM soon but am just doing it all from my local machine as initial proof of concept) So I'm not sure if that cause applies for this scenario. The licence was initially activated by our helpdesk on my old machine, however when I got a new machine. I am pretty sure I activated the licence offline myself. Is there anyway in Ready API to tell which user activated the licence? Could someone please give me some advice about how I could go about fixing this issue. Just in case it is relevant .. I have some SoapUI (open source) / Maven project which I am able to run from Jenkins without issue. I can run the Ready API / Maven project from Maven without any issue. Below is Jenkins console output .. 16:38:20,724 INFO [PluginManager] 0 plugins loaded in 0 ms 16:38:20,724 INFO [DefaultSoapUICore] All plugins loaded No valid SoapUI NG license exists. Please enter absolute path of the license file (.zip or .key): [ERROR] java.util.NoSuchElementException: No line found[JENKINS] Recording test results [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 01:22 min [INFO] Finished at: 2016-11-01T16:38:20+00:00 [INFO] Final Memory: 41M/470M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal com.smartbear:ready-api-maven-plugin:1.9.0:test (default) on project my-myreadyapiapp: Ready! API Test(s) failed: Ready! API Test(s) failed:[ERROR] No line found[ERROR] -> [Help 1][ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.[JENKINS] Archiving C:\MavenProjects\my-myreadyapiapp\pom.xml to com.myreadyapimvnproj.app/my-myreadyapiapp/1.0-SNAPSHOT/my-myreadyapiapp-1.0-SNAPSHOT.pom [ERROR] Re-run Maven using the -X switch to enable full debug logging.[ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles:[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException channel stopped Finished: FAILURE "8 years agoPlace ReadyAPI QuestionsReadyAPI Questions2.8KViews0likes1CommentRe: Running SoapUI / ReadyAPI tests from Maven
Thanks Tanya. I worked this out too. See my reply below. I had the group id set to "com.smartbear" and not "com.smartbear.soapui". However I do still get a lot of ClassNotFoundExceptions. java.lang.ClassNotFoundException: com.eviware.soapui.plugins.auto.factories.AutoDiscoveryMethodFactory I also get these errors every time I run the maven tests .. 14:50:03,120 WARN [Tools] Could not delete temporary directory C:\Users\TAMNOR~1\AppData\Local\Temp\0dba8721-e6d2-4b5e-a3f8-c89e952c2367 Do you know how I can resolve these?8 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.8KViews0likes0CommentsRe: Running SoapUI / ReadyAPI tests from Maven
OK. I worked out why I was getting this error. My group id was set to "com.smartbear" and not "com.smartbear.soapui". I ran mvn test and it worked the first time. Request failed as expected because there was an assertion that was failing, but now I'm running it again and I get ClassNotFoundExceptions ... java.lang.ClassNotFoundException: com.eviware.soapui.plugins.auto.factories.AutoImportMethodFactory I also get these warning messages at the end .. WARN [Tools] Could not delete temporary directory C:\Users\TAMNOR~1\AppData\Local\Temp\dfade0d8-77f1-4763-ba03-bed461ef71f7 There is also the following error .. 13:55:14,673 ERROR [SoapUI] An error occurred [Double slash (//) in path], see error log for details Which doesn't seem right as the URL is shown above. 13:55:14,226 DEBUG [SoapUIMultiThreadedHttpConnectionManager$SoapUIDefaultClientConnection] Sending request: GET /royalmail/uat/mailPieces/AF980715825GB/history HTTP/1.18 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.9KViews0likes0CommentsRunning SoapUI / ReadyAPI tests from Maven
Hi I am trying to figure out how to run my Ready API scripts, or in actual fact SoapUI scripts from Maven. I do actually have a ready API licence, which should be registered to Royal Mail. However I was running into trouble creating a Maven project from my work machine where ReadyAPI is installed. From searching online I suspect this could be due to the fact that requests to download Maven dependencies are going through the proxy. So I am attempting to first do this from my personal machine to make some progress and understand how this works. However I only have SoapUI 5.2.1 installed on this. I have created a Maven project and updated the POM based on the instructions at "http://readyapi.smartbear.com/features/integration/maven/working". I changed the artifact id from .. <artifactId>ready-api-maven-plugin</artifactId> to <artifactId>soapui-maven-plugin</artifactId> and the version and included the correct path to my soapui project. But when I run the command mvn test from the maven project folder where the POM is located I get errors .. Plugin com.smartbear:soapui-maven-plugin:5.2.1 or one of its dependencies could not be resolved: Failure to find com.smartbear: I have attached my POM file and the maven error log. Any help in resolving this would be much appreciated. Regards, Tam Norris8 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.9KViews0likes3Comments