Skip to content

Commit

Permalink
Add changelog reference files with NUKE flavor
Browse files Browse the repository at this point in the history
  • Loading branch information
sandrofigo committed Feb 16, 2023
1 parent 410deff commit c27a246
Show file tree
Hide file tree
Showing 5 changed files with 155 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [vNext]

## [1.2.3] / 2022-01-02
- Added something
- Fixed something

## [1.2.2] / 2022-01-01
- Fixed something

## [0.2.0] / 2020-03-17
- Added something

## [0.1.0] / 2019-03-23
- Added something

Some text at the end of the changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
[
{
IsEmpty: true,
Unreleased: true,
Notes: [

],
StartIndex: 6,
EndIndex: 7
},
{
IsEmpty: false,
Unreleased: false,
Version: 1.2.3,
Notes: [
- Added something,
- Fixed something,

],
StartIndex: 8,
EndIndex: 11
},
{
IsEmpty: false,
Unreleased: false,
Version: 1.2.2,
Notes: [
- Fixed something,

],
StartIndex: 12,
EndIndex: 14
},
{
IsEmpty: false,
Unreleased: false,
Version: 0.2.0,
Notes: [
- Added something,

],
StartIndex: 15,
EndIndex: 17
},
{
IsEmpty: false,
Unreleased: false,
Version: 0.1.0,
Notes: [
- Added something,
,
Some text at the end of the changelog
],
StartIndex: 18,
EndIndex: 21
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [vNext]
- Changed something

## [1.0.0] / 2022-01-02
- Some text that spans
multiple lines
- A text on a single line

- Added something
- Fixed something

## [0.1.0] / 2019-03-23
- Added something

- Fixed something

Some text at the end of the changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
[
{
IsEmpty: false,
Unreleased: true,
Notes: [
- Changed something,

],
StartIndex: 6,
EndIndex: 8
},
{
IsEmpty: false,
Unreleased: false,
Version: 1.0.0,
Notes: [
- Some text that spans,
multiple lines,
- A text on a single line,
,
- Added something,
- Fixed something,

],
StartIndex: 9,
EndIndex: 16
},
{
IsEmpty: false,
Unreleased: false,
Version: 0.1.0,
Notes: [
- Added something,
,
- Fixed something,
,
Some text at the end of the changelog
],
StartIndex: 17,
EndIndex: 22
}
]
11 changes: 11 additions & 0 deletions source/Nuke.Common.Tests/ChangelogTasksTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public class ChangelogTasksTest

[Theory]
[MemberData(nameof(AllChangelogReference_1_0_0_Files))]
[MemberData(nameof(AllChangelogReference_NUKE_Files))]
public void ReadReleaseNotes_ChangelogReferenceFile_ThrowsNoExceptions(AbsolutePath file)
{
Action act = () => ChangelogTasks.ReadReleaseNotes(file);
Expand All @@ -33,6 +34,7 @@ public void ReadReleaseNotes_ChangelogReferenceFile_ThrowsNoExceptions(AbsoluteP

[Theory]
[MemberData(nameof(AllChangelogReference_1_0_0_Files))]
[MemberData(nameof(AllChangelogReference_NUKE_Files))]
public void ReadReleaseNotes_ChangelogReferenceFile_ReturnsAnyReleaseNotes(AbsolutePath file)
{
var releaseNotes = ChangelogTasks.ReadReleaseNotes(file);
Expand All @@ -42,6 +44,7 @@ public void ReadReleaseNotes_ChangelogReferenceFile_ReturnsAnyReleaseNotes(Absol

[Theory]
[MemberData(nameof(AllChangelogReference_1_0_0_Files))]
[MemberData(nameof(AllChangelogReference_NUKE_Files))]
public void ReadChangelog_ChangelogReferenceFile_ThrowsNoExceptions(AbsolutePath file)
{
Action act = () => ChangelogTasks.ReadChangelog(file);
Expand All @@ -51,6 +54,7 @@ public void ReadChangelog_ChangelogReferenceFile_ThrowsNoExceptions(AbsolutePath

[Theory]
[MemberData(nameof(AllChangelogReference_1_0_0_Files))]
[MemberData(nameof(AllChangelogReference_NUKE_Files))]
public void ExtractChangelogSectionNotes_ChangelogReferenceFile_ThrowsNoExceptions(AbsolutePath file)
{
Action act = () => ChangelogTasks.ExtractChangelogSectionNotes(file);
Expand All @@ -60,6 +64,7 @@ public void ExtractChangelogSectionNotes_ChangelogReferenceFile_ThrowsNoExceptio

[Theory]
[MemberData(nameof(AllChangelogReference_1_0_0_Files))]
[MemberData(nameof(AllChangelogReference_NUKE_Files))]
public Task ReadReleaseNotes_ChangelogReferenceFile_HasParsedCorrectly(AbsolutePath file)
{
var releaseNotes = ChangelogTasks.ReadReleaseNotes(file);
Expand Down Expand Up @@ -126,5 +131,11 @@ public static IEnumerable<object[]> AllChangelogReference_1_0_0_Files
{
get => PathToChangelogReferenceFiles.GlobFiles("changelog_reference_1.0.0*.md").Select(file => new object[] { file });
}

[UsedImplicitly]
public static IEnumerable<object[]> AllChangelogReference_NUKE_Files
{
get => PathToChangelogReferenceFiles.GlobFiles("changelog_reference_NUKE*.md").Select(file => new object[] { file });
}
}
}

0 comments on commit c27a246

Please sign in to comment.