use of com.axway.ats.rbv.filesystem.rules.FileMd5Rule in project ats-framework by Axway.
the class Test_FileMD5Rule method isMatchNullMetaDataContent.
@Test(expected = MetaDataIncorrectException.class)
public void isMatchNullMetaDataContent() throws PackageException, RbvException {
expect(pack.getMd5sum(true)).andReturn(md5sum);
replayAll();
FileMd5Rule rule = new FileMd5Rule("", "isMatchNullMetaDataContent", true);
MetaData metaData = new FileSystemMetaData(null);
assertFalse(rule.isMatch(metaData));
verifyAll();
}
use of com.axway.ats.rbv.filesystem.rules.FileMd5Rule in project ats-framework by Axway.
the class FileSystemVerification method checkMd5.
/**
* Add rule to check that the MD5 sum of the received file is the same
* as the MD5 sum of the source file in the selected mode - binary or ASCII
*
* @param srcAtsAgent the remote ATS agent address on which the source file is located
* @param srcFile the full name of the file
* @param binaryMode true to check in binary mode, false to check in ASCII mode
* @throws RbvException thrown on error
*/
@PublicAtsApi
public void checkMd5(String srcAtsAgent, String srcFile, boolean binaryMode) throws RbvException {
FileMd5Rule rule = new FileMd5Rule(srcAtsAgent, srcFile, binaryMode, "checkMd5", true);
rootRule.addRule(rule);
}
use of com.axway.ats.rbv.filesystem.rules.FileMd5Rule in project ats-framework by Axway.
the class FileSystemVerification method checkMd5Different.
/**
* Add rule to check that the MD5 sum of the received file is different
* than the MD5 sum of the source file in the selected mode - binary or ASCII
*
* @param srcAtsAgent the remote ATS agent address on which the source file is located
* @param srcFile the full name of the file
* @param binaryMode true to check in binary mode, false to check in ASCII mode
* @throws RbvException thrown on error
*/
@PublicAtsApi
public void checkMd5Different(String srcAtsAgent, String srcFile, boolean binaryMode) throws RbvException {
FileMd5Rule rule = new FileMd5Rule(srcAtsAgent, srcFile, binaryMode, "checkMd5Different", false);
rootRule.addRule(rule);
}
use of com.axway.ats.rbv.filesystem.rules.FileMd5Rule in project ats-framework by Axway.
the class FileSystemVerification method checkMd5.
/**
* Add rule to check that the MD5 sum of the received file is the same
* as the MD5 sum of the source file
*
* @param srcAtsAgent the remote ATS agent address on which the source file is located
* @param srcFile the full name of the file
* @throws RbvException thrown on error
*/
@PublicAtsApi
public void checkMd5(String srcAtsAgent, String srcFile) throws RbvException {
FileMd5Rule rule = new FileMd5Rule(srcAtsAgent, srcFile, "checkMd5", true);
rootRule.addRule(rule);
}
use of com.axway.ats.rbv.filesystem.rules.FileMd5Rule in project ats-framework by Axway.
the class FileSystemVerification method checkMd5Different.
/**
* Add rule to check that the MD5 sum of the received file is different
* as the given one
*
* @param md5
*/
@PublicAtsApi
public void checkMd5Different(String md5) {
FileMd5Rule rule = new FileMd5Rule(md5, "checkMd5Different", false);
rootRule.addRule(rule);
}
Aggregations