2016-02-09 00:06:13 +00:00
|
|
|
|
// Copyright (c) .NET Foundation and contributors. All rights reserved.
|
|
|
|
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
|
|
|
|
|
|
|
|
using System;
|
|
|
|
|
using System.IO;
|
|
|
|
|
using Microsoft.DotNet.Tools.Test.Utilities;
|
|
|
|
|
using Xunit;
|
|
|
|
|
|
|
|
|
|
namespace Microsoft.DotNet.Tools.Builder.Tests
|
|
|
|
|
{
|
|
|
|
|
public class IncrementalTestsOnResources : IncrementalTestBase
|
|
|
|
|
{
|
2016-02-11 22:17:20 +00:00
|
|
|
|
public IncrementalTestsOnResources()
|
2016-02-09 00:06:13 +00:00
|
|
|
|
{
|
2016-02-11 22:17:20 +00:00
|
|
|
|
MainProject = "TestProjectWithResource";
|
|
|
|
|
ExpectedOutput = "Hello World!" + Environment.NewLine;
|
2016-02-09 00:06:13 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Fact]
|
|
|
|
|
public void TestRebuildSkipsCompilationOnNonCultureResource()
|
|
|
|
|
{
|
2016-02-11 22:17:20 +00:00
|
|
|
|
var testInstance = TestAssetsManager.CreateTestInstance("TestProjectWithResource")
|
|
|
|
|
.WithLockFiles();
|
|
|
|
|
|
|
|
|
|
TestProjectRoot = testInstance.TestRoot;
|
|
|
|
|
|
2016-02-09 00:06:13 +00:00
|
|
|
|
var buildResult = BuildProject();
|
2016-04-13 00:29:07 +00:00
|
|
|
|
buildResult.Should().HaveCompiledProject(MainProject, _appFrameworkFullName);
|
2016-02-09 00:06:13 +00:00
|
|
|
|
|
|
|
|
|
buildResult = BuildProject();
|
2016-04-13 00:29:07 +00:00
|
|
|
|
buildResult.Should().HaveSkippedProjectCompilation(MainProject, _appFrameworkFullName);
|
2016-02-09 00:06:13 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
2016-02-11 22:17:20 +00:00
|
|
|
|
}
|