Mercurial > hg
changeset 32779:2510823ca0df
releasenotes: add more tests for formatting and merging of release notes
author | Rishabh Madan <rishabhmadan96@gmail.com> |
---|---|
date | Sun, 04 Jun 2017 00:16:45 +0200 |
parents | 91e355a0408b |
children | 5e76a07e9f42 |
files | tests/test-releasenotes-formatting.t tests/test-releasenotes-merging.t |
diffstat | 2 files changed, 121 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-releasenotes-formatting.t Fri Jun 02 23:33:30 2017 +0200 +++ b/tests/test-releasenotes-formatting.t Sun Jun 04 00:16:45 2017 +0200 @@ -254,3 +254,73 @@ ------------- * Short summary of fix 3 + +Multiple 'Other Changes' sub-sections for every section + + $ hg init multiple-otherchanges + $ cd multiple-otherchanges + + $ touch fix1 + $ hg -q commit -A -l - << EOF + > commit 1 + > + > .. fix:: Title of First Fix + > + > First paragraph of fix 1. + > EOF + + $ touch feature1 + $ hg -q commit -A -l - << EOF + > commit 2 + > + > .. feature:: Title of First Feature + > + > First paragraph of feature 1. + > EOF + + $ touch feature2 + $ hg -q commit -A -l - << EOF + > commit 3 + > + > .. feature:: + > + > Short summary of feature 2. + > EOF + + $ touch fix2 + $ hg -q commit -A -l - << EOF + > commit 4 + > + > .. fix:: + > + > Short summary of fix 2 + > EOF + + $ hg releasenotes -r 'all()' $TESTTMP/relnotes-multiple-otherchanges + $ cat $TESTTMP/relnotes-multiple-otherchanges + New Features + ============ + + Title of First Feature + ---------------------- + + First paragraph of feature 1. + + Other Changes + ------------- + + * Short summary of feature 2. + + Bug Fixes + ========= + + Title of First Fix + ------------------ + + First paragraph of fix 1. + + Other Changes + ------------- + + * Short summary of fix 2 +
--- a/tests/test-releasenotes-merging.t Fri Jun 02 23:33:30 2017 +0200 +++ b/tests/test-releasenotes-merging.t Sun Jun 04 00:16:45 2017 +0200 @@ -110,3 +110,54 @@ This describes a feature from a commit message. $ cd .. + +Bullets don't merge properly + + $ hg init bullets + $ cd bullets + $ touch fix1 + $ hg -q commit -A -l - << EOF + > commit 1 + > + > .. fix:: + > + > this is fix1. + > EOF + + $ touch fix2 + $ hg -q commit -A -l - << EOF + > commit 2 + > + > .. fix:: + > + > this is fix2. + > EOF + + $ hg releasenotes -r 'all()' $TESTTMP/relnotes-bullet-problem + $ cat $TESTTMP/relnotes-bullet-problem + Bug Fixes + ========= + + * this is fix1. + + * this is fix2. + $ touch fix3 + $ hg -q commit -A -l - << EOF + > commit 3 + > + > .. fix:: + > + > this is fix3. + > EOF + + $ hg releasenotes -r . $TESTTMP/relnotes-bullet-problem + $ cat $TESTTMP/relnotes-bullet-problem + Bug Fixes + ========= + + * this is fix1. + + this is fix2. + + * this is fix3. +