Checks if assay is set before calling the log method

Assay may be not defined in the occasion of a unit test
This commit is contained in:
Felipe Zimmerle 2015-08-10 00:33:27 -03:00
parent 0a91f2aa4d
commit 70b25668b6
23 changed files with 78 additions and 26 deletions

View File

@ -40,7 +40,9 @@ std::string Base64Decode::evaluate(std::string value,
/** /**
* @todo Implement the transformation base64decode * @todo Implement the transformation base64decode
*/ */
assay->debug(4, "Transformation 64 is not implemented yet."); if (assay) {
assay->debug(4, "Transformation 64 is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string Base64DecodeExt::evaluate(std::string value,
/** /**
* @todo Implement the transformation Base64DecodeExt * @todo Implement the transformation Base64DecodeExt
*/ */
assay->debug(4, "Transformation Base64DecodeExt is not implemented yet."); if (assay) {
assay->debug(4, "Transformation Base64DecodeExt is" \
" not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string CmdLine::evaluate(std::string value,
/** /**
* @todo Implement the transformation CmdLine * @todo Implement the transformation CmdLine
*/ */
assay->debug(4, "Transformation CmdLine is not implemented yet."); if (assay) {
assay->debug(4, "Transformation CmdLine is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,8 +40,10 @@ std::string CompressWhitespace::evaluate(std::string value,
/** /**
* @todo Implement the transformation CompressWhitespace * @todo Implement the transformation CompressWhitespace
*/ */
assay->debug(4, "Transformation CompressWhitespace is " \ if (assay) {
"not implemented yet."); assay->debug(4, "Transformation CompressWhitespace is " \
"not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string EscapeSeqDecode::evaluate(std::string value,
/** /**
* @todo Implement the transformation EscapeSeqDecode * @todo Implement the transformation EscapeSeqDecode
*/ */
assay->debug(4, "Transformation EscapeSeqDecode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation EscapeSeqDecode is " \
"not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string HexDecode::evaluate(std::string value,
/** /**
* @todo Implement the transformation HexDecode * @todo Implement the transformation HexDecode
*/ */
assay->debug(4, "Transformation HexDecode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation HexDecode is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string HexEncode::evaluate(std::string value,
/** /**
* @todo Implement the transformation HexEncode * @todo Implement the transformation HexEncode
*/ */
assay->debug(4, "Transformation HexEncode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation HexEncode is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string Length::evaluate(std::string value,
/** /**
* @todo Implement the transformation Length * @todo Implement the transformation Length
*/ */
assay->debug(4, "Transformation Length is not implemented yet."); if (assay) {
assay->debug(4, "Transformation Length is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string Md5::evaluate(std::string value,
/** /**
* @todo Implement the transformation Md5 * @todo Implement the transformation Md5
*/ */
assay->debug(4, "Transformation Md5 is not implemented yet."); if (assay) {
assay->debug(4, "Transformation Md5 is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string NormalisePath::evaluate(std::string value,
/** /**
* @todo Implement the transformation NormalisePath * @todo Implement the transformation NormalisePath
*/ */
assay->debug(4, "Transformation NormalisePath is not implemented yet."); if (assay) {
assay->debug(4, "Transformation NormalisePath is not" \
" implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string ParityEven7bit::evaluate(std::string value,
/** /**
* @todo Implement the transformation ParityEven7bit * @todo Implement the transformation ParityEven7bit
*/ */
assay->debug(4, "Transformation ParityEven7bit is not implemented yet."); if (assay) {
assay->debug(4, "Transformation ParityEven7bit is not" \
" implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string ParityOdd7bit::evaluate(std::string value,
/** /**
* @todo Implement the transformation ParityOdd7bit * @todo Implement the transformation ParityOdd7bit
*/ */
assay->debug(4, "Transformation ParityOdd7bit is not implemented yet."); if (assay) {
assay->debug(4, "Transformation ParityOdd7bit is not " \
"implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,10 @@ std::string ParityZero7bit::evaluate(std::string value,
/** /**
* @todo Implement the transformation ParityZero7bit * @todo Implement the transformation ParityZero7bit
*/ */
assay->debug(4, "Transformation ParityZero7bit is not implemented yet."); if (assay) {
assay->debug(4, "Transformation ParityZero7bit is not" \
"implemented yet.");
}
return value; return value;
} }

View File

@ -40,8 +40,10 @@ std::string RemoveComments::evaluate(std::string value,
/** /**
* @todo Implement the transformation RemoveComments * @todo Implement the transformation RemoveComments
*/ */
assay->debug(4, "Transformation RemoveComments is not " \ if (assay) {
"implemented yet."); assay->debug(4, "Transformation RemoveComments is not " \
"implemented yet.");
}
return value; return value;
} }

View File

@ -40,8 +40,10 @@ std::string RemoveCommentsChar::evaluate(std::string value,
/** /**
* @todo Implement the transformation RemoveCommentsChar * @todo Implement the transformation RemoveCommentsChar
*/ */
assay->debug(4, "Transformation RemoveCommentsChar " \ if (assay) {
"is not implemented yet."); assay->debug(4, "Transformation RemoveCommentsChar " \
"is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string RemoveWhitespace::evaluate(std::string value,
/** /**
* @todo Implement the transformation RemoveWhitespace * @todo Implement the transformation RemoveWhitespace
*/ */
assay->debug(4, "Transformation RemoveWhitespace is not implemented yet."); if (assay) {
assay->debug(4, "Transformation RemoveWhitespace is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string ReplaceComments::evaluate(std::string value,
/** /**
* @todo Implement the transformation ReplaceComments * @todo Implement the transformation ReplaceComments
*/ */
assay->debug(4, "Transformation ReplaceComments is not implemented yet."); if (assay) {
assay->debug(4, "Transformation ReplaceComments is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string ReplaceNulls::evaluate(std::string value,
/** /**
* @todo Implement the transformation ReplaceNulls * @todo Implement the transformation ReplaceNulls
*/ */
assay->debug(4, "Transformation ReplaceNulls is not implemented yet."); if (assay) {
assay->debug(4, "Transformation ReplaceNulls is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string Sha1::evaluate(std::string value,
/** /**
* @todo Implement the transformation Sha1 * @todo Implement the transformation Sha1
*/ */
assay->debug(4, "Transformation Sha1 is not implemented yet."); if (assay) {
assay->debug(4, "Transformation Sha1 is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string SqlHexDecode::evaluate(std::string value,
/** /**
* @todo Implement the transformation SqlHexDecode * @todo Implement the transformation SqlHexDecode
*/ */
assay->debug(4, "Transformation SqlHexDecode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation SqlHexDecode is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string UrlDecode::evaluate(std::string value,
/** /**
* @todo Implement the transformation UrlDecode * @todo Implement the transformation UrlDecode
*/ */
assay->debug(4, "Transformation UrlDecode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation UrlDecode is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string UrlEncode::evaluate(std::string value,
/** /**
* @todo Implement the transformation UrlEncode * @todo Implement the transformation UrlEncode
*/ */
assay->debug(4, "Transformation UrlEncode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation UrlEncode is not implemented yet.");
}
return value; return value;
} }

View File

@ -40,7 +40,9 @@ std::string Utf8Unicode::evaluate(std::string value,
/** /**
* @todo Implement the transformation Utf8Unicode * @todo Implement the transformation Utf8Unicode
*/ */
assay->debug(4, "Transformation Utf8Unicode is not implemented yet."); if (assay) {
assay->debug(4, "Transformation Utf8Unicode is not implemented yet.");
}
return value; return value;
} }