/// <summary> /// Pre-compile Web Applications to optimize startup time for the application. Even though this operation exist in ConDep, we recommend you to pre-compile web applications as part of your build process, and not the deployment process, using aspnet_compiler.exe. /// </summary> /// <param name="webApplicationName"></param> /// <param name="webApplicationPhysicalPath"></param> /// <param name="preCompileOutputpath"></param> /// <returns></returns> public static IOfferLocalOperations PreCompile(this IOfferLocalOperations local, string webApplicationName, string webApplicationPhysicalPath, string preCompileOutputpath) { var operation = new PreCompileOperation(webApplicationName, webApplicationPhysicalPath, preCompileOutputpath); Configure.Operation(local, operation); return local; }
public IOfferLocalOperations PreCompile(string webApplicationName, string webApplicationPhysicalPath, string preCompileOutputpath) { var operation = new PreCompileOperation(webApplicationName, webApplicationPhysicalPath, preCompileOutputpath); _localSequence.Add(operation); return this; }
public void TestThatPreCompileExecutesSuccessfully() { var operation = new PreCompileOperation("MyWebApp", @"C:\temp\MyWebApp", @"C:\temp\MyWebAppCompiled", _buildManager.Object); var status = new StatusReporter(); operation.Execute(status, _settingsDefault, _token); Assert.That(status.HasErrors, Is.False); _buildManager.Verify(manager => manager.PrecompileApplication(It.IsAny<PreCompileCallback>())); }
public void TestThatPreCompileExecutesSuccessfully() { var operation = new PreCompileOperation("MyWebApp", @"C:\temp\MyWebApp", @"C:\temp\MyWebAppCompiled", _buildManager.Object); var status = new StatusReporter(); operation.Execute(status, new ConDepConfig(), new ConDepOptions(false, "", false, false, false, false, null)); Assert.That(status.HasErrors, Is.False); _buildManager.Verify(manager => manager.PrecompileApplication(It.IsAny<PreCompileCallback>())); }
public void TestThatValidationsSucceedsWhenDirectoriesExists() { var operation = new PreCompileOperation("MyWebApp", _validWebAppPath, _validOutputPath, _buildManager.Object); var notification = new Notification(); Assert.That(operation.IsValid(notification)); }
public void TestThatValidationsFailsWhenAppNameIsEmpty() { var operation = new PreCompileOperation("", _validWebAppPath, _validOutputPath, _buildManager.Object); var notification = new Notification(); Assert.That(operation.IsValid(notification), Is.False); }