Web Servces Testing/SoapUI/Groovy program
E. Web Servces Testing/SoapUI/Groovy
def reqF = "C:/SOAPUI/req"
def resF = "C:/SOAPUI/res"
def reqD = new File(reqF)
def resD = new File (resF);
def oracleF = {f1, f2 ->
assert FC.cmpF(f1, f2)== true;
log.info("PASS");
return true;
}
class FC{
def static cmpF(f1, f2) {
def ignoreGUIDs = "-I \"[0-9a-f]\\{32\\}\""
def ignoreDates = "-I \"[0-9]*\\/[0-9]*\\/[0-9]\\{4\\}\""
def diffCmd = "diff -bq --strip-trailing-cr $ignoreGUIDs $ignoreDates ${f1} $f2" //GNU diff
def results = diffCmd.execute()
results.waitFor()
assert results.exitValue() == 0
results.destroy()
return true;
}
}
files = reqD.listFiles();
files2 = resD.listFiles()
for (currentFile in files && currentFile2 in files2)
if(currentFile.exists() && currentile2.exists())
assert oracleF(currentFile,currentFile2) == true;
1. Q: What is the code above doing?
A:
2. Q: Place comments in the code explaining its function.
A:
3. Q: What functional test case would you design to test oracleF?
A:
11 years ago 10
- Essay
- Concisely answer the following questions about the historical discipline: What are primary sources? Secondary sources? Give an example of each. What are...
- What is the role of socio-cultural competencies for the professional manager in making a positive difference to society?
- Payment 5FINALS
- Psychology Research in Context" video. Answer the following questions in a 700- to 1,050-word paper: What was the goal of the present study? How are the present results considered valid? Explain what these results mean to someone who has not taken this c
- Organizational Development and Theory
- Due in 6 hours. IF YOU ARE NOT GOOD IN MATHS DONT WASTE MY TIME PLEASE
- Prof.Mak'Otieno
- Two HOMEWORKS for Globalreserchers
- Project Management