ContributionsMost RecentMost LikesSolutionsUnable to POST multipart/form-data with soapui 5.5.0 (free version) Hi, I am trying to create SOAPUI test suite by using request which consist attachment in it and using "multipart/form-data" Request are following Accept: application/json, text/plain, */* X-REST-API: true X-Requested-With: true User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.130 Safari/537.36 Content-Type: multipart/form-data Accept-Encoding: gzip, deflate and Request Payload is: ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="attachment"; filename="check1.txt" Content-Type: text/plain ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="fileName" check1.txt ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="employeeid" -1 ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="componentid" 213 ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="entityid" 1 ------WebKitFormBoundarylyO2eMQqZPhXMB3d Content-Disposition: form-data; name="categoryId" 151 ------WebKitFormBoundarylyO2eMQqZPhXMB3d-- Tried multiple solutions on smartbear community but unable to get success from any of them: https://community.smartbear.com/t5/SoapUI-Open-Source/How-to-POST-multipart-form-data-with-soapui-4-0-1-free/m-p/31209 POSTMAN request are appearing (refer attached postman image) SOPAUI image which i have created (refer attached soapui images) Please suggest, as i am getting failure while running this soapui request however postman is successfully able to execute the REST request Re: How to copy HTTP test step from one test suite to another test suite I have tried def workspace = testRunner.testCase.testSuite.project.workspace project = workspace.getProjectByName('ProjectName'); apiTestSuite = project.getTestSuiteByName(TestSuite1); apiTestCase = apiTestSuite.getTestCaseByName('TestCase1'); apiTestStep = apiTestCase.getTestStepByName('TestStep1'); testRunner.testCase.testSuite.project.getTestSuiteByName("TestSuite2").getTestCaseByName("TestCase2").cloneTesStep(TestStep1,TestStep1) But, this code is not working Re: groovy script to add HTTP step in test case Thanks for your responses, it really works..I have an another query Looking for a groovy code which will copy test step from one test suite and clone the same step to another test suite for e.g PROJECT1 | ___Test Suite 1 __Test Case1 ___Test Step1 ___Test Suite2 ___Test Case2 would like to clone Test Step1 from Test Case1 to Test Case2 How to copy HTTP test step from one test suite to another test suite Hi, I am looking for a groovy code which will copy test step from one test suite and clone the same step to another test suite for e.g PROJECT1 | ___Test Suite 1 __Test Case1 ___Test Step1 ___Test Suite2 ___Test Case2 would like to clone Test Step1 from Test Case1 to Test Case2, please suggest Re: groovy script to add HTTP step in test case Thanks a lot, Rao, it works... another Help, How could I add XML request in newly created POST type test step I am able to create test step by your code now I want to add below-shown XML in HTTP request <Request Object="System" Action="Logon" Username="ABC" Password="DEF"/> means: how can we add XML request in a body of created test step Re: Clone a step with Groovy script Will this above shown solution work for HTTP type test step as well instead of JDBC type test? Re: groovy script to add HTTP step in test case Hi Rao, In my current scenario, I am able to create test suite and test case by groovy script suite = context.testCase.testSuite.project.addNewTestSuite(suiteName) and in another groovy, I am using the below shown code for creating a test case def testSuite = context.testCase.testSuite.project.getTestSuiteByName(suiteName); def tc = testSuite.addNewTestCase(tcName) Now I want to add "HTTP" test step under above-created test case, I got code to create groovy step in test case tc.addTestStep(GroovyScriptStepFactory.GROOVY_TYPE, "TestStep1") tc.addTestStep(GroovyScriptStepFactory.GROOVY_TYPE, "TestStep2") But unable to find the way to create new test step in desired test case. OR if I will get got groovy code to copy Test step from one test suite to another then that will also work for me... Please suggest groovy script to add HTTP step in test case Hi, I am looking for a groovy script by which i would able to add HTTP type step in my test case. I am able to create/add test case in desire test suite but unable to find a groovy code/script to add HTTP type step in added test cases. Please help. Thanks Sachin chanchal Solved