C# 클래스 NStub.Core.TestProjectBuilder

Builds the test files.
파일 보기 프로젝트 열기: Jedzia/NStub 1 사용 예제들

공개 메소드들

메소드 설명
GenerateTests ( GeneratorRunnerData data ) : void

Generates the tests.

GenerateTests ( string outputFolder, Type generatorType, string inputAssemblyPath, IList mainNodes, IList referencedAssemblies ) : void

Creates a list of the methods for which the user wishes to generate test cases for and instantiates an instance of NStub around these methods. The sources are files are then generated.

TestProjectBuilder ( IBuildSystem sbs, IProjectGenerator projectGenerator, Func createGeneratorCallback, Action logger ) : System

Initializes a new instance of the TestProjectBuilder class.

보호된 메소드들

메소드 설명
OnCreateCodeGenerator ( CodeNamespace codeNamespace, ICodeGeneratorParameters configuration, IBuildSystem buildSystem ) : ICodeGenerator

Called when the TestProjectBuilder is about to create the code generator.

Override this method to instantiate others than the standard generators. The default implementation is:

비공개 메소드들

메소드 설명
CreateMethod ( string methodName, MethodInfo methodInfo ) : CodeMemberMethod
WriteTestFile ( string calculatedOutputDirectory, CodeNamespace codeNamespace ) : void

Writes the test file.

메소드 상세

GenerateTests() 공개 메소드

Generates the tests.
public GenerateTests ( GeneratorRunnerData data ) : void
data GeneratorRunnerData The data that is necessary for test building.
리턴 void

GenerateTests() 공개 메소드

Creates a list of the methods for which the user wishes to generate test cases for and instantiates an instance of NStub around these methods. The sources are files are then generated.
public GenerateTests ( string outputFolder, Type generatorType, string inputAssemblyPath, IList mainNodes, IList referencedAssemblies ) : void
outputFolder string The output folder.
generatorType System.Type Type of the code generator to use.
inputAssemblyPath string The input assembly path.
mainNodes IList The main nodes.
referencedAssemblies IList The list of referenced assemblies.
리턴 void

OnCreateCodeGenerator() 보호된 메소드

Called when the TestProjectBuilder is about to create the code generator.
Override this method to instantiate others than the standard generators. The default implementation is:
protected OnCreateCodeGenerator ( CodeNamespace codeNamespace, ICodeGeneratorParameters configuration, IBuildSystem buildSystem ) : ICodeGenerator
codeNamespace System.CodeDom.CodeNamespace The code namespace.
configuration ICodeGeneratorParameters The configuration.
buildSystem IBuildSystem The build system.
리턴 ICodeGenerator

TestProjectBuilder() 공개 메소드

Initializes a new instance of the TestProjectBuilder class.
public TestProjectBuilder ( IBuildSystem sbs, IProjectGenerator projectGenerator, Func createGeneratorCallback, Action logger ) : System
sbs IBuildSystem The system wide build system.
projectGenerator IProjectGenerator The project generator.
createGeneratorCallback Func The callback to create new code /// generators per test class .
logger Action The logging method.
리턴 System