ipn: add ability to name profiles
Updates #713 Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
@@ -56,6 +56,7 @@ func TestPrefsEqual(t *testing.T) {
|
||||
"NoSNAT",
|
||||
"NetfilterMode",
|
||||
"OperatorUser",
|
||||
"ProfileName",
|
||||
"Persist",
|
||||
}
|
||||
if have := fieldsOf(reflect.TypeOf(Prefs{})); !reflect.DeepEqual(have, prefsHandles) {
|
||||
@@ -272,6 +273,16 @@ func TestPrefsEqual(t *testing.T) {
|
||||
&Prefs{Persist: &persist.Persist{LoginName: "dave"}},
|
||||
true,
|
||||
},
|
||||
{
|
||||
&Prefs{ProfileName: "work"},
|
||||
&Prefs{ProfileName: "work"},
|
||||
true,
|
||||
},
|
||||
{
|
||||
&Prefs{ProfileName: "work"},
|
||||
&Prefs{ProfileName: "home"},
|
||||
false,
|
||||
},
|
||||
}
|
||||
for i, tt := range tests {
|
||||
got := tt.a.Equals(tt.b)
|
||||
|
||||
Reference in New Issue
Block a user