(t *testing.T)
| 644 | } |
| 645 | |
| 646 | func TestUpdateIsolationValid(t *testing.T) { |
| 647 | flags := newUpdateCommand(nil).Flags() |
| 648 | err := flags.Set("isolation", "process") |
| 649 | assert.NilError(t, err) |
| 650 | spec := swarm.ServiceSpec{ |
| 651 | TaskTemplate: swarm.TaskSpec{ |
| 652 | ContainerSpec: &swarm.ContainerSpec{}, |
| 653 | }, |
| 654 | } |
| 655 | err = updateService(context.Background(), nil, flags, &spec) |
| 656 | assert.NilError(t, err) |
| 657 | assert.Check(t, is.Equal(container.IsolationProcess, spec.TaskTemplate.ContainerSpec.Isolation)) |
| 658 | } |
| 659 | |
| 660 | // TestUpdateLimitsReservations tests that limits and reservations are updated, |
| 661 | // and that values are not updated are not reset to their default value |
nothing calls this directly
no test coverage detected
searching dependent graphs…