#2177 Added conversion of 'Hostname' to 'givenName' in a node with FQDN rules applied (#2198)

This commit is contained in:
hopleus 2024-10-15 19:33:03 +03:00 committed by GitHub
parent 52a3b54ba2
commit cc42fc394a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 64 additions and 0 deletions

View file

@ -392,6 +392,15 @@ func TestHeadscale_generateGivenName(t *testing.T) {
want: regexp.MustCompile("^testnode$"),
wantErr: false,
},
{
name: "UPPERCASE node name generation",
args: args{
suppliedName: "TestNode",
randomSuffix: false,
},
want: regexp.MustCompile("^testnode$"),
wantErr: false,
},
{
name: "node name with 53 chars",
args: args{