Elide GraalVM25.6.0-elide.4
All types
Versions and modules

ResultVerifier.SnippetRun

Javaclassin org.graalvm.polyglot.tcksince 0.30

public final class ResultVerifier.SnippetRun
Inheritance
  1. Object
  2. SnippetRun
Enclosing type
ResultVerifier

Provides the test execution data.

Methods5

List<? extends Value> getParameters()

getParameters

since 0.30
public List<? extends Value> getParameters()

Returns the actual parameters of a snippet execution.

Returns

List<? extends Value>
the parameters
Value getResult()

getResult

since 0.30
public Value getResult()

Returns the result of a snippet execution.

Returns

Value
the result of a snippet execution or null in case of execution failure.
PolyglotException getException()

getException

since 0.30
public PolyglotException getException()

Returns the PolyglotException thrown during snippet execution. If the snippet execution throws an IllegalArgumentException, this exception is first converted to a PolyglotException, and the resulting PolyglotException is provided by this method.

Returns

PolyglotException
the PolyglotException thrown during the execution or null in case of successful execution.
static ResultVerifier.SnippetRun create(Snippet, List<? extends Value>, Value)

create

staticsince 0.30
public static ResultVerifier.SnippetRun create(
    Snippet snippet,
    List<? extends Value> parameters,
    Value result
)

Creates a new SnippetRun for successful execution.

Parameters

snippetSnippet
the executed Snippet
parametersList<? extends Value>
the actual parameters of snippet execution
resultValue
the result of snippet execution
static ResultVerifier.SnippetRun create(Snippet, List<? extends Value>, PolyglotException)

create

staticsince 0.30
public static ResultVerifier.SnippetRun create(
    Snippet snippet,
    List<? extends Value> parameters,
    PolyglotException exception
)

Creates a new SnippetRun for failed execution.

Parameters

snippetSnippet
the executed Snippet
parametersList<? extends Value>
the actual parameters of snippet execution
exceptionPolyglotException
the PolyglotException thrown during snippet execution

Inherited members