C# 클래스 Habanero.Testability.ValidValueGeneratorTextFile

Generates random values from a text file. If a filename is not specified, the generator will look for a filename that has the name of the property (e.g. FirstName) with a ".txt" extension. Each item should appear on a different line in the text file. Once the values have been read from the file once, the items are cached in memory for rapid test performance.
상속: ValidValueGenerator
파일 보기 프로젝트 열기: Chillisoft/habanero.testability

공개 메소드들

메소드 설명
GenerateValidValue ( ) : object

Generates a valid value taking into account only the IPropRules. I.e. any InterPropRules will not be taken into account. The IValidValueGeneratorNumeric's methods are used by the BOTestFactory to create valid values taking into account InterPropRules

ValidValueGeneratorTextFile ( ISingleValueDef propDef, string fileName = null ) : System.Collections.Generic

Constructs a new instance of the generator

비공개 메소드들

메소드 설명
CreateSampleValues ( ) : void
GetStringsFromFile ( ) : List

메소드 상세

GenerateValidValue() 공개 메소드

Generates a valid value taking into account only the IPropRules. I.e. any InterPropRules will not be taken into account. The IValidValueGeneratorNumeric's methods are used by the BOTestFactory to create valid values taking into account InterPropRules
public GenerateValidValue ( ) : object
리턴 object

ValidValueGeneratorTextFile() 공개 메소드

Constructs a new instance of the generator
public ValidValueGeneratorTextFile ( ISingleValueDef propDef, string fileName = null ) : System.Collections.Generic
propDef ISingleValueDef The definition of the property for which random values will be generated
fileName string The filename that contains the available values, including the path. If the path is relative, /// it will relate to the execution directory. If no filename is specified, the filename used will be the /// property name (e.g. FirstName) with a ".txt" extension.
리턴 System.Collections.Generic