Skip to content

Commit

Permalink
fix encoding function Brancos (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
martinusso authored Oct 9, 2020
1 parent ace5f40 commit a93d669
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ var (
"SS": regexp.MustCompile(`ß`),
"Z": regexp.MustCompile(`ż`),
"TH": regexp.MustCompile(`þ`),
"% ": regexp.MustCompile(`%`),
}
)

Expand Down
6 changes: 6 additions & 0 deletions utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ func TestBrancos(t *testing.T) {
if expected != got {
t.Errorf("Expected '%s' got '%s'", expected, got)
}

got = Brancos("Todrigo Martins / 50%comissao serly , Claudia , marisa , Hilda ", 40)
expected = "TODRIGO MARTINS / 50% COMISSAO SERLY , C"
if expected != got {
t.Errorf("Expected '%s' got '%s'", expected, got)
}
}

func TestDate(t *testing.T) {
Expand Down

0 comments on commit a93d669

Please sign in to comment.