org.eclipse.emf.emfstore.fuzzy
Interface FuzzyDataProvider<T>

Type Parameters:
T - Type to specify the values created by this data provider.
All Known Implementing Classes:
EMFDataProvider

public interface FuzzyDataProvider<T>

A Data Provider for the JUnit Runner: FuzzyRunner.

An implementation of it must have a zero-parameter constructor.

Author:
Julian Sommerfeldt

Method Summary
 T get(int count)
          Creates and returns the data for the next run.

Note that it is strongly recommended to instantiate the data in this method for every call and not in the instantiation of the class, e.g.
 List<org.junit.runner.notification.RunListener> getListener()
           
 List<Test> getTestsToRun()
           
 Util getUtil()
           
 void init()
          This method is called after the FuzzyDataProvider was created and everything was set BEFORE the first run.
Should be used to to create internal stuff depending on e.g.
 void setOptions(Map<String,Object> options)
           
 void setTestClass(org.junit.runners.model.TestClass testClass)
           
 int size()
           
 

Method Detail

get

T get(int count)
Creates and returns the data for the next run.

Note that it is strongly recommended to instantiate the data in this method for every call and not in the instantiation of the class, e.g. the init method, to avoid overloading the memory.

Parameters:
count - The count of the testcase.
Returns:
The data for the next run of the test class.

init

void init()
This method is called after the FuzzyDataProvider was created and everything was set BEFORE the first run.
Should be used to to create internal stuff depending on e.g. the TestClass.


size

int size()
Returns:
The total size(count) of the repetition of the tests.

setTestClass

void setTestClass(org.junit.runners.model.TestClass testClass)
Parameters:
testClass - The TestClass of the calling FuzzyRunner.

getListener

List<org.junit.runner.notification.RunListener> getListener()
Returns:
A list of listeners to add to the runner, e.g. to get information about errors. null permitted.

getTestsToRun

List<Test> getTestsToRun()
Returns:
A list of Tests to specify, which tests the FuzzyRunner should run. null means run all tests.

getUtil

Util getUtil()
Returns:
The Util for this FuzzyDataProvider. null permitted.

setOptions

void setOptions(Map<String,Object> options)
Parameters:
options - The options for the FuzzyDataProvider. Can be null.


Copyright © 2014. All Rights Reserved.