Package org.apache.jmeter.assertions
Class JSONPathAssertion
-
- All Implemented Interfaces:
-
java.io.Serializable,java.lang.Cloneable,org.apache.jmeter.assertions.Assertion,org.apache.jmeter.gui.Searchable,org.apache.jmeter.testelement.TestElement,org.apache.jmeter.testelement.ThreadListener
public class JSONPathAssertion extends AbstractTestElement implements Serializable, Assertion, ThreadListener
This is main class for JSONPath Assertion which verifies assertion on previous sample result using JSON path expression
- Since:
4.0
-
-
Field Summary
Fields Modifier and Type Field Description public final static StringJSONPATHpublic final static StringEXPECTEDVALUEpublic final static StringJSONVALIDATIONpublic final static StringEXPECT_NULLpublic final static StringINVERTpublic final static StringISREGEXpublic transient JMeterContextthreadContextpublic transient StringthreadNamepublic final static TestElement.CompanionCompanionpublic final static StringNAMEpublic final static StringGUI_CLASSpublic final static StringENABLEDpublic final static StringTEST_CLASSpublic final static StringCOMMENTS
-
Constructor Summary
Constructors Constructor Description JSONPathAssertion()
-
Method Summary
Modifier and Type Method Description StringgetJsonPath()voidsetJsonPath(String jsonPath)StringgetExpectedValue()voidsetExpectedValue(String expectedValue)voidsetJsonValidationBool(boolean jsonValidation)voidsetExpectNull(boolean val)booleanisExpectNull()booleanisJsonValidationBool()voidsetInvert(boolean invert)booleanisInvert()voidsetIsRegex(boolean flag)booleanisUseRegex()AssertionResultgetResult(SampleResult samplerResult)static StringobjectToString(Object subj)voidthreadStarted()voidthreadFinished()-
Methods inherited from class org.apache.jmeter.testelement.AbstractTestElement
addTestElement, canRemove, clear, clearTestElementChildren, clone, equals, getComment, getName, getProperty, getPropertyAsBoolean, getPropertyAsDouble, getPropertyAsFloat, getPropertyAsInt, getPropertyAsLong, getPropertyAsString, getPropertyOrNull, getSearchableTokens, getThreadContext, getThreadName, hashCode, isEnabled, isRunningVersion, isTemporary, propertyIterator, recoverRunningVersion, removeProperty, setComment, setEnabled, setName, setProperty, setRunningVersion, setTemporary, setThreadContext, setThreadName, traverse -
Methods inherited from class org.apache.jmeter.testelement.TestElement
get, get, get, get, get, get, get, get, get, getOrCreate, getOrCreate, getOrNull, getOrNull, getOrNull, getProps, getSchema, getString, removed, set -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getJsonPath
String getJsonPath()
-
setJsonPath
void setJsonPath(String jsonPath)
-
getExpectedValue
String getExpectedValue()
-
setExpectedValue
void setExpectedValue(String expectedValue)
-
setJsonValidationBool
void setJsonValidationBool(boolean jsonValidation)
-
setExpectNull
void setExpectNull(boolean val)
-
isExpectNull
boolean isExpectNull()
-
isJsonValidationBool
boolean isJsonValidationBool()
-
setInvert
void setInvert(boolean invert)
-
isInvert
boolean isInvert()
-
setIsRegex
void setIsRegex(boolean flag)
-
isUseRegex
boolean isUseRegex()
-
getResult
AssertionResult getResult(SampleResult samplerResult)
-
objectToString
static String objectToString(Object subj)
-
threadStarted
void threadStarted()
-
threadFinished
void threadFinished()
-
-
-
-