Making some of the testbase methods protected.

Renaming variables according to code review comments. Adding the folder logic to the builder tests. Creating a separate compilation folder during the build.
This commit is contained in:
Livar Cunha 2016-01-21 15:01:21 -08:00 committed by Livar Cunha
parent b459c3665e
commit fdea0b87e0
24 changed files with 132 additions and 131 deletions

View file

@ -61,10 +61,11 @@ namespace Microsoft.DotNet.Tools.Compiler
ProjectContext context,
CompilerCommandApp args)
{
var outputPath = context.GetOutputPathCalculator(args.OutputValue).GetOutputDirectoryPath(args.ConfigValue);
var outputPathCalculator = context.GetOutputPathCalculator(args.OutputValue);
var outputPath = outputPathCalculator.GetCompilationOutputPath(args.ConfigValue);
var nativeOutputPath = Path.Combine(outputPath, "native");
var intermediateOutputPath =
context.GetIntermediateOutputPath(args.ConfigValue, args.IntermediateValue, outputPath);
var intermediateOutputPath =
outputPathCalculator.GetIntermediateOutputPath(args.ConfigValue, args.IntermediateValue);
var nativeIntermediateOutputPath = Path.Combine(intermediateOutputPath, "native");
Directory.CreateDirectory(nativeOutputPath);
Directory.CreateDirectory(nativeIntermediateOutputPath);
@ -160,8 +161,10 @@ namespace Microsoft.DotNet.Tools.Compiler
private static bool CompileProject(ProjectContext context, CompilerCommandApp args)
{
// Set up Output Paths
var outputPath = context.GetOutputPathCalculator(args.OutputValue).GetOutputDirectoryPath(args.ConfigValue);
string intermediateOutputPath = context.GetIntermediateOutputPath(args.ConfigValue, args.IntermediateValue, outputPath);
var outputPathCalculator = context.GetOutputPathCalculator(args.OutputValue);
var outputPath = outputPathCalculator.GetCompilationOutputPath(args.ConfigValue);
var intermediateOutputPath =
outputPathCalculator.GetIntermediateOutputPath(args.ConfigValue, args.IntermediateValue);
Directory.CreateDirectory(outputPath);
Directory.CreateDirectory(intermediateOutputPath);