mirror of
https://github.com/rlespinasse/github-slug-action.git
synced 2026-05-17 10:25:08 +00:00
tests: add more test cases on v3 around underscore
This commit is contained in:
committed by
GitHub
parent
046be07299
commit
f80aa0fae4
@@ -35,6 +35,11 @@ test('slug: a number', () => {
|
||||
test_slug_cs('4.2', '4.2')
|
||||
})
|
||||
|
||||
test('slug: an underscore', () => {
|
||||
test_slug('An_Underscore', 'an_underscore')
|
||||
test_slug_cs('An_Underscore', 'An_Underscore')
|
||||
})
|
||||
|
||||
test('slug: special character', () => {
|
||||
test_slug('feat-(!è§-character', 'feat------character')
|
||||
test_slug_cs('feat-(!è§-character', 'feat------character')
|
||||
|
||||
@@ -25,6 +25,11 @@ test('slug_ref: a fix branch', () => {
|
||||
test_slugref_cs('refs/heads/fix/issue_number', 'fix-issue_number')
|
||||
})
|
||||
|
||||
test('slug_ref: an underscore', () => {
|
||||
test_slugref('refs/heads/An_Underscore', 'an_underscore')
|
||||
test_slugref_cs('refs/heads/An_Underscore', 'An_Underscore')
|
||||
})
|
||||
|
||||
test('slug_ref: a simple tag', () => {
|
||||
test_slugref('refs/tags/v1.0.0', 'v1.0.0')
|
||||
test_slugref_cs('refs/tags/v1.0.0', 'v1.0.0')
|
||||
|
||||
@@ -35,6 +35,11 @@ test('slug_url: a number', () => {
|
||||
test_slugurl_cs('4.2', '4-2')
|
||||
})
|
||||
|
||||
test('slug_url: an underscore', () => {
|
||||
test_slugurl('An_Underscore', 'an-underscore')
|
||||
test_slugurl_cs('An_Underscore', 'An-Underscore')
|
||||
})
|
||||
|
||||
test('slug_url: trailing', () => {
|
||||
test_slugurl('.path.to.', 'path-to')
|
||||
test_slugurl_cs('.path.to.', 'path-to')
|
||||
|
||||
@@ -25,6 +25,11 @@ test('slug_url_ref: a fix branch', () => {
|
||||
test_slugurlref_cs('refs/heads/fix/issue_number', 'fix-issue-number')
|
||||
})
|
||||
|
||||
test('slug_url_ref: an underscore', () => {
|
||||
test_slugurlref('refs/heads/An_Underscore', 'an-underscore')
|
||||
test_slugurlref_cs('refs/heads/An_Underscore', 'An-Underscore')
|
||||
})
|
||||
|
||||
test('slug_url_ref: a simple tag', () => {
|
||||
test_slugurlref('refs/tags/v1.0.0', 'v1-0-0')
|
||||
test_slugurlref_cs('refs/tags/v1.0.0', 'v1-0-0')
|
||||
|
||||
Reference in New Issue
Block a user