change: update name of method to check and normalize Domain name

This commit is contained in:
Adrien Raffin-Caboisse 2022-03-06 20:46:17 +01:00
parent dcf3ea567c
commit 1114449601
No known key found for this signature in database
GPG key ID: 7FB60532DEBEAD6A
5 changed files with 14 additions and 14 deletions

View file

@ -233,7 +233,7 @@ func (s *Suite) TestGetMapResponseUserProfiles(c *check.C) {
c.Assert(found, check.Equals, true)
}
func TestNormalizeNamespaceName(t *testing.T) {
func TestNormalizeName(t *testing.T) {
type args struct {
name string
stripEmailDomain bool
@ -310,7 +310,7 @@ func TestNormalizeNamespaceName(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
got, err := NormalizeNamespaceName(tt.args.name, tt.args.stripEmailDomain)
got, err := NormalizeName(tt.args.name, tt.args.stripEmailDomain)
if (err != nil) != tt.wantErr {
t.Errorf(
"NormalizeNamespaceName() error = %v, wantErr %v",
@ -327,7 +327,7 @@ func TestNormalizeNamespaceName(t *testing.T) {
}
}
func TestCheckNamespaceName(t *testing.T) {
func TestCheckName(t *testing.T) {
type args struct {
name string
}
@ -366,7 +366,7 @@ func TestCheckNamespaceName(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if err := CheckNamespaceName(tt.args.name); (err != nil) != tt.wantErr {
if err := CheckName(tt.args.name); (err != nil) != tt.wantErr {
t.Errorf("CheckNamespaceName() error = %v, wantErr %v", err, tt.wantErr)
}
})