mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-17 21:01:26 +02:00
Spring cleaning of the menu code
This commit is contained in:
@@ -600,8 +600,8 @@ func TestHopefullyUniqueID(t *testing.T) {
|
||||
|
||||
func TestAddMenuEntryChild(t *testing.T) {
|
||||
root := &MenuEntry{Weight: 1}
|
||||
root.AddChild(&MenuEntry{Weight: 2})
|
||||
root.AddChild(&MenuEntry{Weight: 1})
|
||||
root.addChild(&MenuEntry{Weight: 2})
|
||||
root.addChild(&MenuEntry{Weight: 1})
|
||||
assert.Equal(t, 2, len(root.Children))
|
||||
assert.Equal(t, 1, root.Children[0].Weight)
|
||||
}
|
||||
|
Reference in New Issue
Block a user