bd-211: Remove deprecated rename functions from import_shared.go
- Removed renameImportedIssuePrefixes (wrapper, 3 LOC) - Removed renameImportedIssuePrefixesOld (deprecated, 61 LOC) - Removed replaceIDReferences (32 LOC) - Removed replaceBoundaryAware (31 LOC) - Removed isBoundary (5 LOC) - Removed TestIsBoundary (37 LOC) - Removed TestReplaceBoundaryAware (54 LOC) - Total: 223 LOC removed (136 LOC code + 91 LOC tests) - Active implementation is in internal/importer/importer.go - All tests pass
This commit is contained in:
@@ -4,43 +4,6 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestIsBoundary(t *testing.T) {
|
||||
tests := []struct {
|
||||
input byte
|
||||
expected bool
|
||||
}{
|
||||
{' ', true},
|
||||
{'\t', true},
|
||||
{'\n', true},
|
||||
{'\r', true},
|
||||
{'-', false}, // hyphen is part of issue IDs
|
||||
{'_', true},
|
||||
{'(', true},
|
||||
{')', true},
|
||||
{'[', true},
|
||||
{']', true},
|
||||
{'{', true},
|
||||
{'}', true},
|
||||
{',', true},
|
||||
{'.', true},
|
||||
{':', true},
|
||||
{';', true},
|
||||
{'a', false}, // lowercase letters are part of issue IDs
|
||||
{'z', false},
|
||||
{'A', true}, // uppercase is a boundary
|
||||
{'Z', true}, // uppercase is a boundary
|
||||
{'0', false}, // digits are part of issue IDs
|
||||
{'9', false},
|
||||
}
|
||||
|
||||
for _, tt := range tests {
|
||||
result := isBoundary(tt.input)
|
||||
if result != tt.expected {
|
||||
t.Errorf("isBoundary(%q) = %v, want %v", tt.input, result, tt.expected)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestIsNumeric(t *testing.T) {
|
||||
tests := []struct {
|
||||
input string
|
||||
|
||||
Reference in New Issue
Block a user