15467: Adding KeepServices WIP
[arvados.git] / services / crunch-dispatch-slurm / crunch-dispatch-slurm_test.go
index 6007c6d4a80c5e3d151ed96485fdfabf56c92d1b..4a0213d4777ff78dbd70e58c2f5f28d6daf20fd7 100644 (file)
@@ -396,6 +396,8 @@ func (s *StubbedSuite) TestLoadLegacyConfig(c *C) {
 Client:
   APIHost: example.com
   AuthToken: abcdefg
+  KeepServices:
+    - https://example.com/keep
 SbatchArguments: ["--foo", "bar"]
 PollPeriod: 12s
 PrioritySpread: 42
@@ -431,4 +433,11 @@ BatchSize: 99
        c.Check(s.disp.cluster.Containers.ReserveExtraRAM, Equals, arvados.ByteSize(12345))
        c.Check(s.disp.cluster.Containers.MinRetryPeriod, Equals, arvados.Duration(13*time.Second))
        c.Check(s.disp.cluster.API.MaxItemsPerResponse, Equals, 99)
+       c.Check(s.disp.cluster.Containers.SLURM.KeepServices, DeepEquals, map[string]Service{
+               "00000-bi6l4-000000000000000": Service{
+                       InternalURLs: map[string]struct{}{
+                               "https://example.com/keep": struct{}{},
+                       },
+               },
+       })
 }