-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #213 from Airblader/feature-172
Allow adding tags dynamically and also allow tags on Stage classes and Stage methods
- Loading branch information
Showing
16 changed files
with
418 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
jgiven-core/src/main/java/com/tngtech/jgiven/CurrentScenario.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.tngtech.jgiven; | ||
|
||
import java.lang.annotation.Annotation; | ||
|
||
import com.tngtech.jgiven.annotation.ScenarioState; | ||
|
||
/** | ||
* This interface can be injected into a stage using the {@link ScenarioState} annotation. | ||
* It provided programmatic access to the current scenario. | ||
* | ||
* @since 0.12.0 | ||
*/ | ||
public interface CurrentScenario { | ||
|
||
/** | ||
* Dynamically add a tag to the scenario. | ||
* @param annotationClass The tag annotation class to use. | ||
* @param values List of custom values. | ||
* @since 0.12.0 | ||
*/ | ||
void addTag( Class<? extends Annotation> annotationClass, String... values ); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
jgiven-core/src/main/java/com/tngtech/jgiven/impl/ScenarioExecutor.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.