Skip to content

Commit 09e3a4d

Browse files
authored
fix(parser-angular): change Fixes commit type heading to Bug Fixes (#1064)
* test(fixtures): update expected changelog heading to `Bug Fixes` * test(unit): update expected changelog heading to `Bug Fixes`
1 parent 9dca116 commit 09e3a4d

File tree

9 files changed

+20
-20
lines changed

9 files changed

+20
-20
lines changed

semantic_release/commit_parser/angular.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def _logged_parse_error(commit: Commit, error: str) -> ParseError:
3535
"chore": "chores",
3636
"docs": "documentation",
3737
"feat": "features",
38-
"fix": "fixes",
38+
"fix": "bug fixes",
3939
"perf": "performance improvements",
4040
"refactor": "refactoring",
4141
"style": "code style",

tests/fixtures/repos/git_flow/repo_w_2_release_channels.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def get_commits_for_git_flow_repo_with_2_release_channels() -> GetRepoDefinition
5555
},
5656
"0.1.1-rc.1": {
5757
"changelog_sections": {
58-
"angular": [{"section": "Fixes", "i_commits": [0]}],
58+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
5959
"emoji": [{"section": ":bug:", "i_commits": [0]}],
6060
"scipy": [{"section": "Fix", "i_commits": [0]}],
6161
"tag": [{"section": "Fix", "i_commits": [0]}],
@@ -152,7 +152,7 @@ def get_commits_for_git_flow_repo_with_2_release_channels() -> GetRepoDefinition
152152
},
153153
"1.1.1": {
154154
"changelog_sections": {
155-
"angular": [{"section": "Fixes", "i_commits": [0]}],
155+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
156156
"emoji": [{"section": ":bug:", "i_commits": [0]}],
157157
"scipy": [{"section": "Fix", "i_commits": [0]}],
158158
"tag": [{"section": "Fix", "i_commits": [0]}],
@@ -209,8 +209,8 @@ def get_commits_for_git_flow_repo_with_2_release_channels() -> GetRepoDefinition
209209
# But value is ultimately defined by the commits, which means the commits are
210210
# referenced by index value
211211
"angular": [
212+
{"section": "Bug Fixes", "i_commits": [1]},
212213
{"section": "Features", "i_commits": [0]},
213-
{"section": "Fixes", "i_commits": [1]},
214214
],
215215
"emoji": [
216216
{"section": ":bug:", "i_commits": [1]},

tests/fixtures/repos/git_flow/repo_w_3_release_channels.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def get_commits_for_git_flow_repo_w_3_release_channels() -> GetRepoDefinitionFn:
5555
},
5656
"0.1.1-rc.1": {
5757
"changelog_sections": {
58-
"angular": [{"section": "Fixes", "i_commits": [0]}],
58+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
5959
"emoji": [{"section": ":bug:", "i_commits": [0]}],
6060
"scipy": [{"section": "Fix", "i_commits": [0]}],
6161
"tag": [{"section": "Fix", "i_commits": [0]}],
@@ -152,7 +152,7 @@ def get_commits_for_git_flow_repo_w_3_release_channels() -> GetRepoDefinitionFn:
152152
},
153153
"1.1.0-rc.2": {
154154
"changelog_sections": {
155-
"angular": [{"section": "Fixes", "i_commits": [0]}],
155+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
156156
"emoji": [{"section": ":bug:", "i_commits": [0]}],
157157
"scipy": [{"section": "Fix", "i_commits": [0]}],
158158
"tag": [{"section": "Fix", "i_commits": [0]}],
@@ -230,7 +230,7 @@ def get_commits_for_git_flow_repo_w_3_release_channels() -> GetRepoDefinitionFn:
230230
},
231231
"1.1.0-alpha.3": {
232232
"changelog_sections": {
233-
"angular": [{"section": "Fixes", "i_commits": [0]}],
233+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
234234
"emoji": [{"section": ":bug:", "i_commits": [0]}],
235235
"scipy": [{"section": "Fix", "i_commits": [0]}],
236236
"tag": [{"section": "Fix", "i_commits": [0]}],

tests/fixtures/repos/github_flow/repo_w_release_channels.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def get_commits_for_github_flow_repo_w_feature_release_channel() -> GetRepoDefin
5555
},
5656
"0.1.1-rc.1": {
5757
"changelog_sections": {
58-
"angular": [{"section": "Fixes", "i_commits": [0]}],
58+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
5959
"emoji": [{"section": ":bug:", "i_commits": [0]}],
6060
"scipy": [{"section": "Fix", "i_commits": [0]}],
6161
"tag": [{"section": "Fix", "i_commits": [0]}],

tests/fixtures/repos/trunk_based_dev/repo_w_no_tags.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ def get_commits_for_trunk_only_repo_w_no_tags() -> GetRepoDefinitionFn:
4242
# But value is ultimately defined by the commits, which means the commits are
4343
# referenced by index value
4444
"angular": [
45+
{"section": "Bug Fixes", "i_commits": [3, 1]},
4546
{"section": "Features", "i_commits": [2]},
46-
{"section": "Fixes", "i_commits": [3, 1]},
4747
{"section": "Unknown", "i_commits": [0]},
4848
],
4949
"emoji": [

tests/fixtures/repos/trunk_based_dev/repo_w_prereleases.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def get_commits_for_trunk_only_repo_w_prerelease_tags() -> GetRepoDefinitionFn:
5555
},
5656
"0.1.1-rc.1": {
5757
"changelog_sections": {
58-
"angular": [{"section": "Fixes", "i_commits": [0]}],
58+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
5959
"emoji": [{"section": ":bug:", "i_commits": [0]}],
6060
"scipy": [{"section": "Fix", "i_commits": [0]}],
6161
"tag": [{"section": "Fix", "i_commits": [0]}],

tests/fixtures/repos/trunk_based_dev/repo_w_tags.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def get_commits_for_trunk_only_repo_w_tags() -> GetRepoDefinitionFn:
5555
},
5656
"0.1.1": {
5757
"changelog_sections": {
58-
"angular": [{"section": "Fixes", "i_commits": [0]}],
58+
"angular": [{"section": "Bug Fixes", "i_commits": [0]}],
5959
"emoji": [{"section": ":bug:", "i_commits": [0]}],
6060
"scipy": [{"section": "Fix", "i_commits": [0]}],
6161
"tag": [{"section": "Fix", "i_commits": [0]}],

tests/unit/semantic_release/changelog/test_changelog_context.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def changelog_tpl_github_context() -> str:
3939
4040
{{ "[Change Summary](%s)" | format("v1.0.0" | compare_url("v2.0.0")) }}
4141
42-
### Fixes
42+
### Bug Fixes
4343
4444
- Fixed a minor bug {{ "([#%s](%s))" | format(22, 22 | pull_request_url) }}
4545
- **cli:** fix a problem {{ "([%s](%s))" | format("000000", "000000" | commit_hash_url) }}
@@ -62,7 +62,7 @@ def changelog_tpl_gitea_context() -> str:
6262
6363
## v2.0.0
6464
65-
### Fixes
65+
### Bug Fixes
6666
6767
- Fixed a minor bug {{ "([#%s](%s))" | format(22, 22 | pull_request_url) }}
6868
- **cli:** fix a problem {{ "([%s](%s))" | format("000000", "000000" | commit_hash_url) }}
@@ -87,7 +87,7 @@ def changelog_tpl_gitlab_context() -> str:
8787
8888
{{ "[Change Summary](%s)" | format("v1.0.0" | compare_url("v2.0.0")) }}
8989
90-
### Fixes
90+
### Bug Fixes
9191
9292
- Fixed a minor bug {{ "([#%s](%s))" | format(22, 22 | merge_request_url) }}
9393
- Fixed a performance bug {{ "([#%s](%s))" | format(25, 25 | pull_request_url) }}
@@ -113,7 +113,7 @@ def changelog_tpl_bitbucket_context() -> str:
113113
114114
{{ "[Change Summary](%s)" | format("v1.0.0" | compare_url("v2.0.0")) }}
115115
116-
### Fixes
116+
### Bug Fixes
117117
118118
- Fixed a minor bug {{ "([#%s](%s))" | format(22, 22 | pull_request_url) }}
119119
- **cli:** fix a problem {{ "([%s](%s))" | format("000000", "000000" | commit_hash_url) }}
@@ -197,7 +197,7 @@ def test_changelog_context_bitbucket(
197197
"",
198198
f'[Change Summary]({hvcs.compare_url("v1.0.0", "v2.0.0")})',
199199
"",
200-
"### Fixes",
200+
"### Bug Fixes",
201201
"",
202202
f"- Fixed a minor bug ([#22]({hvcs.pull_request_url(22)}))",
203203
f'- **cli:** fix a problem ([000000]({hvcs.commit_hash_url("000000")}))',
@@ -241,7 +241,7 @@ def test_changelog_context_github(
241241
"",
242242
f'[Change Summary]({hvcs.compare_url("v1.0.0", "v2.0.0")})',
243243
"",
244-
"### Fixes",
244+
"### Bug Fixes",
245245
"",
246246
f"- Fixed a minor bug ([#22]({hvcs.pull_request_url(22)}))",
247247
f'- **cli:** fix a problem ([000000]({hvcs.commit_hash_url("000000")}))',
@@ -287,7 +287,7 @@ def test_changelog_context_gitea(
287287
"",
288288
"## v2.0.0",
289289
"",
290-
"### Fixes",
290+
"### Bug Fixes",
291291
"",
292292
f"- Fixed a minor bug ([#22]({hvcs.pull_request_url(22)}))",
293293
f'- **cli:** fix a problem ([000000]({hvcs.commit_hash_url("000000")}))',
@@ -335,7 +335,7 @@ def test_changelog_context_gitlab(
335335
"",
336336
f'[Change Summary]({hvcs.compare_url("v1.0.0", "v2.0.0")})',
337337
"",
338-
"### Fixes",
338+
"### Bug Fixes",
339339
"",
340340
f"- Fixed a minor bug ([#22]({hvcs.merge_request_url(22)}))",
341341
f"- Fixed a performance bug ([#25]({hvcs.pull_request_url(25)}))",

tests/unit/semantic_release/commit_parser/test_angular.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def test_parser_returns_correct_bump_level(
6464
"message, type_",
6565
[
6666
("feat(parser): ...", "features"),
67-
("fix(parser): ...", "fixes"),
67+
("fix(parser): ...", "bug fixes"),
6868
("test(parser): ...", "testing"),
6969
("docs(parser): ...", "documentation"),
7070
("style(parser): ...", "code style"),

0 commit comments

Comments
 (0)