(t *testing.T)
| 1124 | } |
| 1125 | |
| 1126 | func TestAutoAcceptMultipleFolders(t *testing.T) { |
| 1127 | // Multiple new folders |
| 1128 | id1 := srand.String(8) |
| 1129 | defer os.RemoveAll(id1) |
| 1130 | id2 := srand.String(8) |
| 1131 | defer os.RemoveAll(id2) |
| 1132 | m, cancel := newState(t, defaultAutoAcceptCfg) |
| 1133 | defer cleanupModel(m) |
| 1134 | defer cancel() |
| 1135 | m.ClusterConfig(device1Conn, createClusterConfig(device1, id1, id2)) |
| 1136 | if fcfg, ok := m.cfg.Folder(id1); !ok || !fcfg.SharedWith(device1) { |
| 1137 | t.Error("expected shared", id1) |
| 1138 | } |
| 1139 | if fcfg, ok := m.cfg.Folder(id2); !ok || !fcfg.SharedWith(device1) { |
| 1140 | t.Error("expected shared", id2) |
| 1141 | } |
| 1142 | } |
| 1143 | |
| 1144 | func TestAutoAcceptExistingFolder(t *testing.T) { |
| 1145 | // Existing folder |
nothing calls this directly
no test coverage detected