Fix placement parser panic (#1121)

This commit is contained in:
Hang Yan
2019-04-04 15:31:06 -04:00
committed by Charlie Drage
parent 06468b2f63
commit fb7a92ca5e
2 changed files with 10 additions and 2 deletions
+4 -1
View File
@@ -386,7 +386,10 @@ func TestCheckLabelsPorts(t *testing.T) {
func TestCheckPlacementCustomLabels(t *testing.T) {
placement := types.Placement{
Constraints: []string{"node.labels.something == anything"},
Constraints: []string{
"node.labels.something == anything",
"node.labels.monitor != xxx",
},
}
output := loadV3Placement(placement.Constraints)