Yes, you’re right. There was a need for this type of test. Therefore, I divided the test case into small ones, since it is huge in its whole form. I made a separation in the form of “_ _ _ _” so that it was clear where the new test case begins.
WebUI.click(findTestObject(‘Object Repository/Operators OTI/Page_/Operators OTI add’))
GlobalVariable.nameOTI = RandomStringUtils.randomAlphanumeric(7)
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/FullNameOTI’), GlobalVariable.nameOTI)
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/SmallNameOTI’), ‘’ + RandomStringUtils.randomAlphanumeric(
9))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/code1c’), ‘’ + RandomStringUtils.randomAlphanumeric(
6))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/213213123123’), ‘’ + RandomStringUtils.randomNumeric(
12))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/Post address’), ‘’ + RandomStringUtils.randomNumeric(
6))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/Telephone’), ‘’ + RandomStringUtils.randomNumeric(11))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/DopTelephone’), ‘’ + RandomStringUtils.randomNumeric(
11))
WebUI.setText(findTestObject(‘Object Repository/Operators OTI/Page_/email’), ‘’ + RandomStringUtils.randomAlphanumeric(9))
WebUI.click(findTestObject(‘Object Repository/Operators OTI/Page_/Save’))
WebUI.click(findTestObject(‘Object Repository/Operators OTI/Page_/Accept’))
WebUI.click(findTestObject(‘Object Repository/Operators OTI/Page_/Back on the list’))
WebUI.refresh()
WebUI.delay(5)
WebUI.clearText(findTestObject(‘Operators OTI/Page_/search a new operator OTI’))
WebUI.click(findTestObject(‘Operators OTI/Page_/search a new operator OTI’))
WebUI.sendKeys(findTestObject(‘Operators OTI/Page_/search a new operator OTI’), GlobalVariable.nameOTI)
WebUI.click(findTestObject(‘Operators OTI/Page_/Search’))
WebUI.delay(3)
def response = WS.sendRequest(findTestObject(‘Postman/api/v1/oti/operator/all/Полный список операторов ОТИ’))
statusCode = WS.getResponseStatusCode(response)
WS.verifyResponseStatusCode(response, 200)
assertThat(response.getStatusCode()).isEqualTo(200)
WebUI.click(findTestObject(‘Operators OTI/Page_/Menu’))
WebUI.click(findTestObject(‘Operators OTI/Page_/Editing’))
…next end test case…