public class OnStage extends Object
screenplay.pronouns = il,elle
The current stage is kept as a ThreadLocal object, so if you have multiple threads in the same Screenplay test,
you need to propagate the stage to each new thread using the setTheStage() method.| Constructor and Description |
|---|
OnStage() |
| Modifier and Type | Method and Description |
|---|---|
static Actor |
aNewActor()
Create a new actor whose name is not yet known.
|
static void |
drawTheCurtain()
Perform any cleanup actions on each actor on the stage.
|
static Stage |
setTheStage(Cast cast)
Set the stage before calling the actors
|
static Stage |
setTheStage(Stage stage)
Set the stage to a specific stage object.
|
static Stage |
stage()
Get the current stage.
|
static Actor |
theActor(String actorName)
A shorter version of "theActorCalled()"
|
static Actor |
theActorCalled(String requiredActor)
Returns an actor with a given name, creating a new actor if the actor is not already on stage.
|
static Actor |
theActorInTheSpotlight()
The actor in the spotlight is the last actor on the stage who has performed any activity.
|
static void |
withCurrentActor(Performable... performTasks)
A shorter version of "theActorInTheSpotlight().attemptsTo(...)"
|
public static Stage setTheStage(Stage stage)
public static Actor theActorCalled(String requiredActor)
public static Actor aNewActor()
public static Actor theActorInTheSpotlight()
public static void withCurrentActor(Performable... performTasks)
public static Stage stage()
public static void drawTheCurtain()
Copyright © 2021. All rights reserved.