public class ESXMIResourceDataProvider extends Object implements ESFuzzyEMFDataProvider
ESFuzzyDataProvider
provides
models by reading them from a models folder.
The run of a test is based on a TestConfig, defining model etc.
TestResults to create a test run for
reporting purpose.| Modifier and Type | Field and Description |
|---|---|
static String |
MODELS_FOLDER_NAME
The name of the folder that contains the models.
|
static String |
MUTATOR_EDITINGDOMAIN
Options constant for the
EditingDomain for the mutator. |
static String |
MUTATOR_EXC_LOG
Options constant for the exception log set for the mutator.
|
static String |
PROP_CONFIGS_FILE
Property specifying the path to the config file for the
ESXMIResourceDataProvider. |
static String |
PROP_EMFDATAPROVIDER
Prefix of the properties concerning the
ESXMIResourceDataProvider. |
| Constructor and Description |
|---|
ESXMIResourceDataProvider() |
| Modifier and Type | Method and Description |
|---|---|
void |
finish()
Call finish as last action of the
ESXMIResourceDataProvider. |
org.eclipse.emf.ecore.EObject |
get(int count)
See
ESFuzzyDataProvider. |
ESTestConfig |
getConfig()
Returns the config specifying this run of this provider.
|
int |
getCurrentSeedCount()
Returns the current seed that is used to generate the model.
|
Collection<org.eclipse.emf.ecore.EPackage> |
getEPackages()
Returns a collection of
EPackages that are
being considered to be generated/mutated. |
List<org.junit.runner.notification.RunListener> |
getListener() |
ESModelMutatorConfiguration |
getModelMutatorConfiguration()
Returns the currently active
ESModelMutatorConfiguration. |
long |
getSeed()
Returns the current seed for this data provider.
|
List<ESFuzzyTest> |
getTestsToRun() |
ESFuzzyUtil |
getUtil() |
void |
init()
Initializes the
ESXMIResourceDataProvider. |
void |
setMutator(ESAbstractModelMutator modelMutator)
Sets the mutator to be used in order to generate and mutate data.
|
void |
setOptions(Map<String,Object> options)
Set the options for the
ESXMIResourceDataProvider. |
void |
setTestClass(org.junit.runners.model.TestClass testClass) |
int |
size() |
public static final String MODELS_FOLDER_NAME
public static final String PROP_EMFDATAPROVIDER
ESXMIResourceDataProvider.public static final String PROP_CONFIGS_FILE
ESXMIResourceDataProvider.public static final String MUTATOR_EXC_LOG
Set of RuntimeException.public static final String MUTATOR_EDITINGDOMAIN
EditingDomain for the mutator.public void init()
ESXMIResourceDataProvider.init in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>public org.eclipse.emf.ecore.EObject get(int count)
ESFuzzyDataProvider.get in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>count - Which run is it?EObject.public void finish()
ESXMIResourceDataProvider. Used for
saving the results.public int size()
size in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>public void setTestClass(org.junit.runners.model.TestClass testClass)
setTestClass in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>testClass - The TestClass of this run.public List<org.junit.runner.notification.RunListener> getListener()
getListener in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>RunListener of this ESXMIResourceDataProvider.public List<ESFuzzyTest> getTestsToRun()
getTestsToRun in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>ESFuzzyTests to run or null if all tests should run.public int getCurrentSeedCount()
ESFuzzyEMFDataProvidergetCurrentSeedCount in interface ESFuzzyEMFDataProviderpublic long getSeed()
ESFuzzyEMFDataProvidergetSeed in interface ESFuzzyEMFDataProviderpublic Collection<org.eclipse.emf.ecore.EPackage> getEPackages()
ESFuzzyEMFDataProviderEPackages that are
being considered to be generated/mutated.getEPackages in interface ESFuzzyEMFDataProviderEPackage of the model to generate/mutate.public ESFuzzyUtil getUtil()
getUtil in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>ESMutateUtil for this ESXMIResourceDataProvider.public ESTestConfig getConfig()
ESFuzzyEMFDataProvidergetConfig in interface ESFuzzyEMFDataProviderESXMIResourceDataProvider.public void setOptions(Map<String,Object> options)
ESXMIResourceDataProvider.setOptions in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>options - the options.public ESModelMutatorConfiguration getModelMutatorConfiguration()
ESFuzzyEMFDataProviderESModelMutatorConfiguration.getModelMutatorConfiguration in interface ESFuzzyEMFDataProvidergetModelMutatorConfiguration in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>ESModelMutatorConfiguration.public void setMutator(ESAbstractModelMutator modelMutator)
setMutator in interface ESFuzzyDataProvider<org.eclipse.emf.ecore.EObject>modelMutator - the ESAbstractModelMutator to be usedESFuzzyDataProvider.setMutator(org.eclipse.emf.emfstore.modelmutator.ESAbstractModelMutator)Copyright © 2017. All rights reserved.