Skip to content

Commit 0b99a41

Browse files
authored
Merge pull request #43 from nunit/release-3.7.1
Release 3.7.1
2 parents 73d6d23 + 80a503a commit 0b99a41

11 files changed

+158
-147
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,3 +180,4 @@ MockAssemblyResult.xml
180180
PortabilityAnalysis*.html
181181
tools
182182
!tools/packages.config
183+
DraftRelease.md

CHANGES.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
## NUnit Project Loader Extension 3.7.1 - September 17, 2021
2+
3+
This release serves as a final test of our build automation.
4+
There are no changes other than those related to the build.
5+
6+
### Build
7+
8+
* 35 Update Cake to version 1.2.0
9+
* 37 Change default branch from master to main
10+
* 38 Standardize build scripts for extensions
11+
* 41 Automate the GitHub release process
12+
13+
## NUnit Project Loader Extension 3.7.0 - August 29, 2021
14+
15+
No new features or bug fixes but includes changes in the build script
16+
to facilitate moving to the next major version of the extension, v4.0.
17+
18+
This is expected to be the final release of the 3.x series.
19+
20+
### Issues Resolved
21+
22+
* 17 Add functional package tests to build
23+
* 18 Automate publication of packages
24+
* 20 Update Cake version and get build working again
25+
* 23 Refactor Cake scripts
26+
* 33 Specify console versions for each test separately
27+
28+
## NUnit Project Loader Extension 3.6.0 - July 28, 2017
29+
30+
Fixes several packaging errors and adds a new chocolatey package. Runners and engines
31+
installed under chocolatey will see and make use of this package.
32+
33+
### Issues Resolved
34+
35+
* 2 Change API reference to released version
36+
* 4 Create file of constants for XML element and attribute names
37+
* 7 No license file in NuGet package
38+
* 8 Integrate chocolatey package in release build script
39+
40+
## NUnit Project Loader Extension 3.5.0 - October 6, 2016
41+
42+
The first independent release of the nunit-project-loader extension.

CHANGES.txt

Lines changed: 0 additions & 30 deletions
This file was deleted.

GitReleaseManager.yaml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# The labels that will be used to include issues in release notes.
2+
issue-labels-include:
3+
- Feature
4+
- Enhancement
5+
- Bug
6+
- Build
7+
- Documentation
8+
# The labels that will NOT be used when including issues in release notes.
9+
issue-labels-exclude:
10+
- Refactor
11+
# Overrides default pluralization and header names for specific labels.
12+
issue-labels-alias:
13+
- name: Build
14+
header: Build
15+
plural: Build
16+
- name: Documentation
17+
header: Documentation
18+
plural: Documentation
19+
# Configuration values used when creating new releases
20+
create:
21+
include-footer: true
22+
footer-heading: Packages
23+
footer-content: >-
24+
There are two different packages available for the extension.
25+
<ul>
26+
<li>For a chocolatey install: `nunit-extension-nunit-v2-result-writer.{milestone}.nupkg`
27+
<li>For a nuget install: `NUnit.Extension.NUnitV2ResultWriter.{milestone}.nupkg`
28+
</ul>
29+
You may also download the extension from
30+
[chocolatey.org](https://chocolatey.org/packages/nunit-extension-nunit-v2-result-writer/)
31+
or [nuget.org](https://nuget.org/packages/NUnit.Extension.NUnitV2ResultWriter/).
32+
footer-includes-milestone: true
33+
milestone-replace-text: '{milestone}'
34+
include-sha-section: true
35+
sha-section-heading: "SHA256 Hashes of the release artifacts"
36+
sha-section-line-format: "- `{1}\t{0}`"
37+
allow-update-to-published: false
38+
# Configuration values used when exporting release notes
39+
export:
40+
include-created-date-in-title: true
41+
created-date-string-format: MMMM dd, yyyy
42+
perform-regex-removal: false
43+
# regex-text: '### Where to get it(\r\n)*You can .*\.'
44+
# multiline-regex: false
45+
# Configuration values used when closing a milestone
46+
close:
47+
# Whether to add comments to issues closed with the published milestone release.
48+
use-issue-comments: true
49+
issue-comment: |-
50+
:tada: This issue has been resolved in version {milestone} :tada:
51+
52+
The release is available on:
53+
54+
- [GitHub Release](https://github.com/{owner}/{repository}/releases/tag/{milestone})
55+
- [NuGet Package](https://www.nuget.org/packages/NUnit.Extension.NUnitV2ResultWriter/{milestone})
56+
- [Chocolatey Package](https://chocolatey.org/packages/nunit-extension-nunit-v2-result-writer/{milestone})

build.cake

Lines changed: 8 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#tool nuget:?package=GitVersion.CommandLine&version=5.0.0
2+
#tool nuget:?package=GitReleaseManager&version=0.11.0
23
#tool nuget:?package=NUnit.ConsoleRunner&version=3.12.0
34
#tool nuget:?package=NUnit.ConsoleRunner&version=3.11.1
45
#tool nuget:?package=NUnit.ConsoleRunner&version=3.10.0
@@ -12,7 +13,7 @@ const string NUGET_ID = "NUnit.Extension.NUnitProjectLoader";
1213
const string CHOCO_ID = "nunit-extension-nunit-project-loader";
1314
const string GITHUB_OWNER = "nunit";
1415
const string GITHUB_REPO = "nunit-project-loader";
15-
const string DEFAULT_VERSION = "3.8.0";
16+
const string DEFAULT_VERSION = "3.7.1";
1617
const string DEFAULT_CONFIGURATION = "Release";
1718

1819
// Load scripts after defining constants
@@ -26,7 +27,7 @@ var target = Argument("target", "Default");
2627

2728
// Additional arguments defined in the cake scripts:
2829
// --configuration
29-
// --version
30+
// --packageVersion
3031

3132
//////////////////////////////////////////////////////////////////////
3233
// SETUP AND TEARDOWN
@@ -65,16 +66,6 @@ Task("Clean")
6566
CleanDirectory(parameters.OutputDirectory);
6667
});
6768

68-
Task("CleanAll")
69-
.Does<BuildParameters>((parameters) =>
70-
{
71-
Information("Cleaning all output directories");
72-
CleanDirectory(parameters.ProjectDirectory + "bin/");
73-
74-
Information("Deleting object directories");
75-
DeleteObjectDirectories(parameters);
76-
});
77-
7869
//////////////////////////////////////////////////////////////////////
7970
// INITIALIZE FOR BUILD
8071
//////////////////////////////////////////////////////////////////////
@@ -161,7 +152,7 @@ Task("VerifyNuGetPackage")
161152
.Does<BuildParameters>((parameters) =>
162153
{
163154
Check.That(parameters.NuGetInstallDirectory,
164-
HasFiles("CHANGES.txt", "LICENSE.txt"),
155+
HasFiles("CHANGES.md", "LICENSE.txt"),
165156
HasDirectory("tools").WithFile("nunit-project-loader.dll"));
166157
Information("Verification was successful!");
167158
});
@@ -201,7 +192,7 @@ Task("VerifyChocolateyPackage")
201192
{
202193
Check.That(parameters.ChocolateyInstallDirectory,
203194
HasDirectory("tools").WithFiles(
204-
"CHANGES.txt", "LICENSE.txt", "VERIFICATION.txt", "nunit-project-loader.dll"));
195+
"CHANGES.md", "LICENSE.txt", "VERIFICATION.txt", "nunit-project-loader.dll"));
205196
Information("Verification was successful!");
206197
});
207198

@@ -383,21 +374,6 @@ Task("CreateDraftRelease")
383374
}
384375
});
385376

386-
Task("ExportDraftRelease")
387-
.Description("Export draft release locally for use in updating CHANGES.md")
388-
.Does<BuildParameters>((parameters) =>
389-
{
390-
if (parameters.IsReleaseBranch && parameters.IsLocalBuild)
391-
{
392-
string milestone = parameters.BranchName.Substring(8);
393-
394-
GitReleaseManagerExport(parameters.GitHubAccessToken, GITHUB_OWNER, GITHUB_REPO, "DraftRelease.md",
395-
new GitReleaseManagerExportSettings() { TagName = milestone });
396-
}
397-
else
398-
Error("ExportDraftRelease may only be run locally, using a release branch!");
399-
});
400-
401377
//////////////////////////////////////////////////////////////////////
402378
// CREATE A PRODUCTION RELEASE
403379
//////////////////////////////////////////////////////////////////////
@@ -455,7 +431,9 @@ Task("Appveyor")
455431
.IsDependentOn("Build")
456432
.IsDependentOn("Test")
457433
.IsDependentOn("Package")
458-
.IsDependentOn("PublishPackages");
434+
.IsDependentOn("PublishPackages")
435+
.IsDependentOn("CreateDraftRelease")
436+
.IsDependentOn("CreateProductionRelease");
459437

460438
Task("Default")
461439
.IsDependentOn("Build");

cake/local-targets.cake

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
////////////////////////////////////////////////////////////////////
2+
// TARGETS FOR DEVELOPER USE ON LOCAL MACHINE
3+
//////////////////////////////////////////////////////////////////////
4+
5+
using System;
6+
7+
// Dependent task for all local targets
8+
Task("MustBeLocalBuild")
9+
.Does<BuildParameters>((parameters) =>
10+
{
11+
if (!parameters.IsLocalBuild)
12+
throw new Exception($"{parameters.Target} may only be run locally!");
13+
});
14+
15+
Task("CleanAll")
16+
.Description("Clean both configs and all obj directories")
17+
.IsDependentOn("MustBeLocalBuild")
18+
.Does<BuildParameters>((parameters) =>
19+
{
20+
Information("Cleaning all output directories");
21+
CleanDirectory(parameters.ProjectDirectory + "bin/");
22+
23+
Information("Deleting object directories");
24+
DeleteObjectDirectories(parameters);
25+
});
26+
27+
// Download existing draft release for modification or for use in
28+
// updating the CHANGES.md file.
29+
Task("DownloadDraftRelease")
30+
.Description("Download draft release for local use")
31+
.IsDependentOn("MustBeLocalBuild")
32+
.Does<BuildParameters>((parameters) =>
33+
{
34+
if (!parameters.IsReleaseBranch)
35+
throw new Exception("DownloadDraftRelease requires a release branch!");
36+
37+
string milestone = parameters.BranchName.Substring(8);
38+
39+
GitReleaseManagerExport(parameters.GitHubAccessToken, GITHUB_OWNER, GITHUB_REPO, "DraftRelease.md",
40+
new GitReleaseManagerExportSettings() { TagName = milestone });
41+
});
42+

cake/packaging.cake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ static readonly string[] OWNERS = new[] { "Charlie Poole" };
88
const string DESCRIPTION = "This extension allows NUnit to create result files in the V2 format, which is used by many CI servers.";
99
const string SUMMARY = "NUnit Engine extension for writing test result files in NUnit V2 format.";
1010
const string COPYRIGHT = "Copyright (c) 2016 Charlie Poole";
11-
static readonly string[] RELEASE_NOTES = new[] { "See https://raw.githubusercontent.com/nunit/nunit-v2-result-writer/main/CHANGES.txt" };
11+
static readonly string[] RELEASE_NOTES = new[] { "See https://raw.githubusercontent.com/nunit/nunit-v2-result-writer/main/CHANGES.md" };
1212
static readonly string[] TAGS = new[] { "nunit", "test", "testing", "tdd", "runner" };
1313
static readonly Uri PROJECT_URL = new Uri("http://nunit.org");
1414
static readonly Uri ICON_URL = new Uri("https://cdn.rawgit.com/nunit/resources/master/images/icon/nunit_256.png");
@@ -29,7 +29,7 @@ public void BuildNuGetPackage(BuildParameters parameters)
2929
{
3030
var content = new List<NuSpecContent>();
3131
content.Add(new NuSpecContent { Source = parameters.ProjectDirectory + "LICENSE.txt" });
32-
content.Add(new NuSpecContent { Source = parameters.ProjectDirectory + "CHANGES.txt" });
32+
content.Add(new NuSpecContent { Source = parameters.ProjectDirectory + "CHANGES.md" });
3333
content.Add(new NuSpecContent { Source = parameters.OutputDirectory + "net20/nunit-project-loader.dll", Target = "tools" });
3434

3535
NuGetPack(
@@ -66,7 +66,7 @@ public void BuildChocolateyPackage(BuildParameters parameters)
6666
{
6767
var content = new List<ChocolateyNuSpecContent>();
6868
content.Add(new ChocolateyNuSpecContent { Source = parameters.ProjectDirectory + "LICENSE.txt", Target = "tools" });
69-
content.Add(new ChocolateyNuSpecContent { Source = parameters.ProjectDirectory + "CHANGES.txt", Target = "tools" });
69+
content.Add(new ChocolateyNuSpecContent { Source = parameters.ProjectDirectory + "CHANGES.md", Target = "tools" });
7070
content.Add(new ChocolateyNuSpecContent { Source = parameters.ProjectDirectory + "VERIFICATION.txt", Target = "tools" });
7171
content.Add(new ChocolateyNuSpecContent { Source = parameters.OutputDirectory + "net20/nunit-project-loader.dll", Target = "tools" });
7272

cake/parameters.cake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#load "./test-results.cake"
66
#load "./test-reports.cake"
77
#load "./utilities.cake"
8+
#load "./local-targets.cake"
89

910
using System;
1011

cake/versioning.cake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ public class BuildVersion
2323
IsReleaseBranch = BranchName.StartsWith("release-");
2424

2525
// TODO: Get GitVersion to work on Linux
26-
string packageVersion = context.HasArgument("version")
27-
? context.Argument("version", DEFAULT_VERSION)
26+
string packageVersion = context.HasArgument("packageVersion")
27+
? context.Argument("packageVersion", DEFAULT_VERSION)
2828
: CalculatePackageVersion();
2929

3030
int dash = packageVersion.IndexOf('-');

nunit-project-loader.sln

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
1515
build.cake = build.cake
1616
build.ps1 = build.ps1
1717
build.sh = build.sh
18-
CHANGES.txt = CHANGES.txt
18+
CHANGES.md = CHANGES.md
1919
FailingAssembly.nunit = FailingAssembly.nunit
20+
GitReleaseManager.yaml = GitReleaseManager.yaml
2021
GitVersion.yml = GitVersion.yml
2122
LICENSE.txt = LICENSE.txt
2223
nunit-project-loader.nuspec = nunit-project-loader.nuspec
@@ -26,6 +27,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
2627
EndProject
2728
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "cake", "cake", "{1E689680-AB9D-497E-8FC3-B541A9A24EEC}"
2829
ProjectSection(SolutionItems) = preProject
30+
cake\local-targets.cake = cake\local-targets.cake
2931
cake\package-checks.cake = cake\package-checks.cake
3032
cake\package-tests.cake = cake\package-tests.cake
3133
cake\packaging.cake = cake\packaging.cake

0 commit comments

Comments
 (0)