Package org.ff4j.test
Class AssertFf4j
java.lang.Object
org.ff4j.test.AssertFf4j
Give utilities method for tests.
- Author:
- Cedrick LUNVEN
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal AssertFf4jassertThatCurrentUserIsAllowedOnFeature(String featureName) Check Feature Allowed.final AssertFf4jassertThatCurrentUserIsNotAllowedOnFeature(String featureName) Check Feature Allowed.final AssertFf4jassertThatFeatureDoesNotExist(String featureName) Check inexistence of the traget featurefinal AssertFf4jassertThatFeatureDoesNotHaveFlippingStrategy(String featureName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureDoesNotHaveProperties(String featureName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureExist(String featureName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureFlipped(String featureName) Check Feature Flippedfinal AssertFf4jassertThatFeatureHasFlippingStrategy(String featureName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureHasNotProperty(String featureName, String propertyName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureHasNotRole(String featureName, String roleName) Check that feature exists and does not have expected role.final AssertFf4jassertThatFeatureHasProperties(String featureName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureHasProperty(String featureName, String propertyName) Check existence of the traget featurefinal AssertFf4jassertThatFeatureHasRole(String featureName, String roleName) Check that feature exists and have expected role.final AssertFf4jassertThatFeatureIsDisabled(String featureName) Chack that feature is disabled in current store.final AssertFf4jassertThatFeatureIsEnabled(String featureName) Chack that feature is enabled in current store.final AssertFf4jassertThatFeatureIsInGroup(String featureName, String groupName) Check that feature is in expected group.final AssertFf4jassertThatFeatureNotFlipped(String featureName) Check Feature Flippedfinal AssertFf4jassertThatFeatureNotInGroup(String featureName, String groupName) Check that feature is in expected group.assertThatGroupDoesNotExist(String groupName) Check that group does not existfinal AssertFf4jassertThatGroupExist(String groupName) Check Group Sizefinal AssertFf4jassertThatGroupHasSize(int expected, String groupName) Check Group Sizefinal AssertFf4jassertThatPropertyDoesNotExist(String propertyName) Check existence of the traget propertyfinal AssertFf4jassertThatPropertyExist(String propertyName) Check existence of the traget propertyfinal AssertFf4jassertThatPropertyStoreHasSize(int expectedNumber) Check Number of featuresfinal AssertFf4jassertThatStoreHasNumberOfGroups(int expectedNumber) Check Number of featuresfinal AssertFf4jassertThatStoreHasSize(int expectedNumber) Check Number of featuresvoidsetPause(int pause) void
-
Field Details
-
IS_MANDATORY
error message.- See Also:
-
FEATURE
error message.- See Also:
-
-
Constructor Details
-
AssertFf4j
public AssertFf4j(org.ff4j.FF4j cff4j) Initialisation with current ff4j context.- Parameters:
ff4j- current ff4k context
-
-
Method Details
-
setPause
public void setPause(int pause) -
assertThatFeatureExist
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatPropertyExist
Check existence of the traget property- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureDoesNotExist
Check inexistence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatPropertyDoesNotExist
Check existence of the traget property- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureFlipped
Check Feature Flipped- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatFeatureNotFlipped
Check Feature Flipped- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatCurrentUserIsAllowedOnFeature
Check Feature Allowed.- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatCurrentUserIsNotAllowedOnFeature
Check Feature Allowed.- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatStoreHasSize
Check Number of features- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatPropertyStoreHasSize
Check Number of features- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatStoreHasNumberOfGroups
Check Number of features- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatFeatureHasRole
Check that feature exists and have expected role.- Parameters:
featureName- target feature NameroleName- target role name- Returns:
- current object
-
assertThatFeatureHasNotRole
Check that feature exists and does not have expected role.- Parameters:
featureName- target feature NameroleName- target role name- Returns:
- current object
-
assertThatFeatureIsInGroup
Check that feature is in expected group.- Parameters:
featureName- target feature NameroleName- target role name- Returns:
- current object
-
assertThatFeatureNotInGroup
Check that feature is in expected group.- Parameters:
featureName- target feature NameroleName- target role name- Returns:
- current object
-
assertThatFeatureIsEnabled
Chack that feature is enabled in current store.- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatFeatureIsDisabled
Chack that feature is disabled in current store.- Parameters:
featureName- target featureName- Returns:
- current object
-
assertThatGroupExist
Check Group Size- Parameters:
expected- expected value for sizegroupName- target groupName- Returns:
- current object
-
assertThatGroupDoesNotExist
Check that group does not exist- Parameters:
expected- expected value for sizegroupName- target groupName- Returns:
- current object
-
assertThatGroupHasSize
Check Group Size- Parameters:
expected- expected value for sizegroupName- target groupName- Returns:
- current object
-
assertThatFeatureHasFlippingStrategy
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureDoesNotHaveFlippingStrategy
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureHasProperties
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureDoesNotHaveProperties
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureHasProperty
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
assertThatFeatureHasNotProperty
Check existence of the traget feature- Parameters:
featureName- targte featurename- Returns:
- current object
-
waitSomeSeconds
public void waitSomeSeconds()
-