junitparams
Annotation Type FileParameters


@Retention(value=RUNTIME)
@Target(value=METHOD)
public @interface FileParameters

Denotes that parameters for a annotated test method should be taken from an external resource.

Author:
Pawel Lipinski

Required Element Summary
 String value
          File name (with full path) of the file with data.
 
Optional Element Summary
 String encoding
          Encoding to use when reading file contents.
 Class<? extends DataMapper> mapper
          The mapper which knows how to get the data from the external resource and turn it into a valid set of parameters.
 

Element Detail

value

public abstract String value
File name (with full path) of the file with data.

mapper

public abstract Class<? extends DataMapper> mapper
The mapper which knows how to get the data from the external resource and turn it into a valid set of parameters. By default it is an IdentityMapper, meaning the resource has exactly the same format as the

@Parameters annotation value (when passed as String), being CSV.

Default:
junitparams.mappers.IdentityMapper.class

encoding

public abstract String encoding
Encoding to use when reading file contents.

Default:
"UTF-8"


Copyright © 2017 Pragmatists. All rights reserved.