Skip to content

Commit

Permalink
Merge branch 'release/0.17.0' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
devlead committed Nov 9, 2016
2 parents fb23be4 + 541526b commit 1cf2c36
Show file tree
Hide file tree
Showing 198 changed files with 11,065 additions and 584 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ chmod +x build.sh

So you’re thinking about contributing to Cake? Great! It’s **really** appreciated.

Make sure you've read the [contribution guidelines](http://cakebuild.net/contribute/contribution-guidelines/) before sending that epic pull request.
Make sure you've read the [contribution guidelines](http://cakebuild.net/contribute/contribution-guidelines/) before sending that epic pull request. You'll also need to sign the [contribution license agreement](https://cla2.dotnetfoundation.org/) (CLA) for anything other than a trivial change. **NOTE:** The .Net Foundation CLA Bot will provide a link to this CLA within the PR that you submit if it is deemed as required.

* Fork the repository.
* Create a branch to work in.
Expand Down Expand Up @@ -150,6 +150,10 @@ This project has adopted the code of conduct defined by the [Contributor Covenan
to clarify expected behavior in our community.
For more information see the [.NET Foundation Code of Conduct](http://www.dotnetfoundation.org/code-of-conduct).

## Contribution License Agreement

By signing the [CLA](https://cla2.dotnetfoundation.org/), the community is free to use your contribution to .NET Foundation projects.

## .NET Foundation

This project is supported by the [.NET Foundation](http://www.dotnetfoundation.org).
45 changes: 45 additions & 0 deletions ReleaseNotes.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,48 @@
### New on 0.17.0 (Released 2016/11/09)

* Allow custom loggers in the VSTestSettings
* Add support for InnoSetup
* Add a "Prepend" extension for the ProcessArgumentBuilder
* Add Support for the Go.CD build provider
* Add GitLab CI build system support
* Add VSTS build system support
* Wait for AppVeyor process to exit
* Add Ability to Redirect Standard Error on IProcess
* Add option to keep the autogenerated NuSpec file
* IsDependentOn with CakeTaskBuilder parameter
* CopyFiles doesn't respect source directory structure
* Add DotCover Report
* Support OctoPack
* Add support for moving directories
* Typo in VSTestSettings extension method name
* Globber exception when using a path with an exclamation
* Error: An item with the same key has already been added while running Cake from commit hooks
* System time separator is used when Octo DeployAt argument is converted to string
* Unquoted VSTest settings file path
* Globber exception when glob contains %
* GetEntryAssembly can return null, leading to NullReferenceException
* NuGetPack fails if no Files have been specified
* Add support fort Specifying Dependencies for Multi Target package
* Support DefaultCredentials usage for Http Downloads
* Add additional parameters to MSBuild runner
* Add Go.CD build history API call
* Some properties for RoundhouseSettings in Cake.Common.Tools.Roundhouse are not working properly
* Add user agent for DownloadFile
* Guard against invalid path environment variables
* Adding all current parameters for VSTest
* OctoCreateRelease is missing channel option
* Option to deploy an existing release in OctopusDeploy
* Get return code from intercepted process in SpecFlow TestExecutionReport
* Add parameter LogFile to DotCover commands
* Can't specify hash algorithm for the Sign command
* MSBuild add log file support
* Support for SHA256 code signing
* Fixed typos 'occured' and 'occuring'
* Add CLA link to README.
* Removed erroneous apostrophes
* Corrects the grammar "do/does" in exception messages and tests
* Adds default CPU count behavior to MSBuild settings documentation

### New on 0.16.2 (Released 2016/10/11)

* Fixed CakeExecuteScript getting access denied errors on mono/m
Expand Down
2 changes: 1 addition & 1 deletion build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Param(
[string[]]$ScriptArgs
)

$CakeVersion = "0.16.0"
$CakeVersion = "0.16.2"
$DotNetChannel = "preview";
$DotNetVersion = "1.0.0-preview2-003121";
$DotNetInstallerUri = "https://raw.githubusercontent.com/dotnet/cli/rel/1.0.0-preview2/scripts/obtain/dotnet-install.ps1";
Expand Down
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
TOOLS_DIR=$SCRIPT_DIR/tools
NUGET_EXE=$TOOLS_DIR/nuget.exe
NUGET_URL=https://dist.nuget.org/win-x86-commandline/latest/nuget.exe
CAKE_VERSION=0.16.0
CAKE_VERSION=0.16.2
CAKE_EXE=$TOOLS_DIR/Cake.$CAKE_VERSION/Cake.exe

# Define default arguments.
Expand Down
31 changes: 31 additions & 0 deletions src/Cake.Common.Tests/Fixtures/Build/GitLabCIFixture.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Cake.Common.Build.GitLabCI;
using Cake.Core;
using NSubstitute;

namespace Cake.Common.Tests.Fixtures.Build
{
internal sealed class GitLabCIFixture
{
public ICakeEnvironment Environment { get; set; }

public GitLabCIFixture()
{
Environment = Substitute.For<ICakeEnvironment>();
Environment.GetEnvironmentVariable("CI_SERVER").Returns((string)null);
}

public void IsRunningOnGitLabCI()
{
Environment.GetEnvironmentVariable("CI_SERVER").Returns("yes");
}

public GitLabCIProvider CreateGitLabCIService()
{
return new GitLabCIProvider(Environment);
}
}
}
76 changes: 76 additions & 0 deletions src/Cake.Common.Tests/Fixtures/Build/GitLabCIInfoFixture.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Cake.Common.Build.GitLabCI.Data;
using Cake.Core;
using NSubstitute;

namespace Cake.Common.Tests.Fixtures.Build
{
internal sealed class GitLabCIInfoFixture
{
public ICakeEnvironment Environment { get; set; }

public GitLabCIInfoFixture()
{
Environment = Substitute.For<ICakeEnvironment>();

// Example values taken from https://docs.gitlab.com/ce/ci/variables/README.html
Environment.GetEnvironmentVariable("CI_SERVER").Returns("yes");
Environment.GetEnvironmentVariable("CI_BUILD_ID").Returns("50");
Environment.GetEnvironmentVariable("CI_BUILD_REF").Returns("1ecfd275763eff1d6b4844ea3168962458c9f27a");
Environment.GetEnvironmentVariable("CI_BUILD_REF_NAME").Returns("master");
Environment.GetEnvironmentVariable("CI_BUILD_REPO").Returns("https://gitab-ci-token:abcde-1234ABCD5678ef@gitlab.com/gitlab-org/gitlab-ce.git");
Environment.GetEnvironmentVariable("CI_BUILD_TAG").Returns("1.0.0");
Environment.GetEnvironmentVariable("CI_BUILD_NAME").Returns("spec:other");
Environment.GetEnvironmentVariable("CI_BUILD_STAGE").Returns("test");
Environment.GetEnvironmentVariable("CI_BUILD_MANUAL").Returns("true");
Environment.GetEnvironmentVariable("CI_BUILD_TRIGGERED").Returns("true");
Environment.GetEnvironmentVariable("CI_BUILD_TOKEN").Returns("abcde-1234ABCD5678ef");
Environment.GetEnvironmentVariable("CI_PIPELINE_ID").Returns("1000");
Environment.GetEnvironmentVariable("CI_PROJECT_ID").Returns("34");
Environment.GetEnvironmentVariable("CI_PROJECT_DIR").Returns("/builds/gitlab-org/gitlab-ce");
Environment.GetEnvironmentVariable("CI_PROJECT_NAME").Returns("gitlab-ce");
Environment.GetEnvironmentVariable("CI_PROJECT_NAMESPACE").Returns("gitlab-org");
Environment.GetEnvironmentVariable("CI_PROJECT_PATH").Returns("gitlab-org/gitlab-ce");
Environment.GetEnvironmentVariable("CI_PROJECT_URL").Returns("https://gitlab.com/gitlab-org/gitlab-ce");
Environment.GetEnvironmentVariable("CI_REGISTRY").Returns("registry.gitlab.com");
Environment.GetEnvironmentVariable("CI_REGISTRY_IMAGE").Returns("registry.gitlab.com/gitlab-org/gitlab-ce");
Environment.GetEnvironmentVariable("CI_RUNNER_ID").Returns("10");
Environment.GetEnvironmentVariable("CI_RUNNER_DESCRIPTION").Returns("my runner");
Environment.GetEnvironmentVariable("CI_RUNNER_TAGS").Returns("docker, linux");
Environment.GetEnvironmentVariable("CI_SERVER").Returns("yes");
Environment.GetEnvironmentVariable("CI_SERVER_NAME").Returns("GitLab");
Environment.GetEnvironmentVariable("CI_SERVER_REVISION").Returns("70606bf");
Environment.GetEnvironmentVariable("CI_SERVER_VERSION").Returns("8.9.0");
Environment.GetEnvironmentVariable("GITLAB_USER_ID").Returns("42");
Environment.GetEnvironmentVariable("GITLAB_USER_EMAIL").Returns("anthony@warwickcontrol.com");
}

public GitLabCIBuildInfo CreateBuildInfo()
{
return new GitLabCIBuildInfo(Environment);
}

public GitLabCIProjectInfo CreateProjectInfo()
{
return new GitLabCIProjectInfo(Environment);
}

public GitLabCIRunnerInfo CreateRunnerInfo()
{
return new GitLabCIRunnerInfo(Environment);
}

public GitLabCIServerInfo CreateServerInfo()
{
return new GitLabCIServerInfo(Environment);
}

public GitLabCIEnvironmentInfo CreateEnvironmentInfo()
{
return new GitLabCIEnvironmentInfo(Environment);
}
}
}
35 changes: 35 additions & 0 deletions src/Cake.Common.Tests/Fixtures/Build/GoCDFixture.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Cake.Common.Build.GoCD;
using Cake.Core;
using Cake.Testing;
using NSubstitute;

namespace Cake.Common.Tests.Fixtures.Build
{
internal sealed class GoCDFixture
{
public ICakeEnvironment Environment { get; set; }

public FakeLog CakeLog { get; set; }

public GoCDFixture()
{
Environment = Substitute.For<ICakeEnvironment>();
Environment.GetEnvironmentVariable("https://127.0.0.1:8154/go").Returns((string)null);
CakeLog = new FakeLog();
}

public void IsRunningOnGoCD()
{
Environment.GetEnvironmentVariable("GO_SERVER_URL").Returns("https://127.0.0.1:8154/go");
}

public GoCDProvider CreateGoCDService()
{
return new GoCDProvider(Environment, CakeLog);
}
}
}
63 changes: 63 additions & 0 deletions src/Cake.Common.Tests/Fixtures/Build/GoCDInfoFixture.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Cake.Common.Build.GoCD.Data;
using Cake.Core;
using NSubstitute;

namespace Cake.Common.Tests.Fixtures.Build
{
internal sealed class GoCDInfoFixture
{
public ICakeEnvironment Environment { get; set; }

public GoCDInfoFixture()
{
Environment = Substitute.For<ICakeEnvironment>();

// GoCDEnvironmentInfo
Environment.GetEnvironmentVariable("GO_SERVER_URL").Returns("https://127.0.0.1:8154/go");
Environment.GetEnvironmentVariable("GO_ENVIRONMENT_NAME").Returns("Development");
Environment.GetEnvironmentVariable("GO_JOB_NAME").Returns("linux-firefox");
Environment.GetEnvironmentVariable("GO_TRIGGER_USER").Returns("changes");

// GoCDPipelineInfo
Environment.GetEnvironmentVariable("GO_PIPELINE_NAME").Returns("main");
Environment.GetEnvironmentVariable("GO_PIPELINE_COUNTER").Returns("2345");
Environment.GetEnvironmentVariable("GO_PIPELINE_LABEL").Returns("1.1.2345");

// GoCDCommitInfo
Environment.GetEnvironmentVariable("bamboo_planRepository_revision").Returns("d4a3a4cb304548450e3cab2ff735f778ffe58d03");

// GoCDRepositoryInfo
Environment.GetEnvironmentVariable("GO_REVISION").Returns("123");
Environment.GetEnvironmentVariable("GO_TO_REVISION").Returns("124");
Environment.GetEnvironmentVariable("GO_FROM_REVISION").Returns("122");

// GoCDStageInfo
Environment.GetEnvironmentVariable("GO_STAGE_NAME").Returns("dev");
Environment.GetEnvironmentVariable("GO_STAGE_COUNTER").Returns("1");
}

public GoCDEnvironmentInfo CreateEnvironmentInfo()
{
return new GoCDEnvironmentInfo(Environment);
}

public GoCDPipelineInfo CreatePipelineInfo()
{
return new GoCDPipelineInfo(Environment);
}

public GoCDRepositoryInfo CreateRepositoryInfo()
{
return new GoCDRepositoryInfo(Environment);
}

public GoCDStageInfo CreateStageInfo()
{
return new GoCDStageInfo(Environment);
}
}
}
39 changes: 39 additions & 0 deletions src/Cake.Common.Tests/Fixtures/Build/TFBuildFixture.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Cake.Common.Build.TFBuild;
using Cake.Core;
using NSubstitute;

namespace Cake.Common.Tests.Fixtures.Build
{
internal sealed class TFBuildFixture
{
public ICakeEnvironment Environment { get; set; }

public TFBuildFixture()
{
Environment = Substitute.For<ICakeEnvironment>();
Environment.WorkingDirectory.Returns("C:\\build\\CAKE-CAKE-JOB1");
Environment.GetEnvironmentVariable("TF_BUILD").Returns((string)null);
}

public void IsRunningOnVSTS()
{
Environment.GetEnvironmentVariable("TF_BUILD").Returns("True");
Environment.GetEnvironmentVariable("AGENT_NAME").Returns("Hosted Agent");
}

public void IsRunningOnTFS()
{
Environment.GetEnvironmentVariable("TF_BUILD").Returns("True");
Environment.GetEnvironmentVariable("AGENT_NAME").Returns("On Premises");
}

public TFBuildProvider CreateTFBuildService()
{
return new TFBuildProvider(Environment);
}
}
}
Loading

0 comments on commit 1cf2c36

Please sign in to comment.