5
0
mirror of https://github.com/wailsapp/wails.git synced 2025-05-02 11:10:47 +08:00

Add nested anonymous struct test

This commit is contained in:
Lea Anthony 2023-02-25 08:27:36 +11:00
parent cc1a6a3d50
commit 4a8917ecbc
No known key found for this signature in database
GPG Key ID: 33DAF7BB90A58405
2 changed files with 23 additions and 1 deletions

View File

@ -884,6 +884,25 @@ func TestParseDirectory(t *testing.T) {
Name: "int",
},
},
{
Name: "Address",
Type: &ParameterType{
Name: "anon2",
IsStruct: true,
Package: "main",
},
},
},
},
"anon2": {
Name: "anon2",
Fields: []*Field{
{
Name: "Street",
Type: &ParameterType{
Name: "string",
},
},
},
},
},

View File

@ -12,7 +12,10 @@ type Person struct {
Name string
Parent *Person
Details struct {
Age int
Age int
Address struct {
Street string
}
}
}