Merge branch '15028-cwl-v1.1' refs #15028
[arvados.git] / lib / config / deprecated_test.go
1 // Copyright (C) The Arvados Authors. All rights reserved.
2 //
3 // SPDX-License-Identifier: AGPL-3.0
4
5 package config
6
7 import (
8         "os"
9
10         check "gopkg.in/check.v1"
11 )
12
13 func (s *LoadSuite) TestDeprecatedNodeProfilesToServices(c *check.C) {
14         hostname, err := os.Hostname()
15         c.Assert(err, check.IsNil)
16         s.checkEquivalent(c, `
17 Clusters:
18  z1111:
19   NodeProfiles:
20    "*":
21     arvados-controller:
22      listen: ":9004"
23    `+hostname+`:
24     arvados-api-server:
25      listen: ":8000"
26    dispatch-host:
27     arvados-dispatch-cloud:
28      listen: ":9006"
29 `, `
30 Clusters:
31  z1111:
32   Services:
33    RailsAPI:
34     InternalURLs:
35      "http://localhost:8000": {}
36    Controller:
37     InternalURLs:
38      "http://localhost:9004": {}
39    DispatchCloud:
40     InternalURLs:
41      "http://dispatch-host:9006": {}
42   NodeProfiles:
43    "*":
44     arvados-controller:
45      listen: ":9004"
46    `+hostname+`:
47     arvados-api-server:
48      listen: ":8000"
49    dispatch-host:
50     arvados-dispatch-cloud:
51      listen: ":9006"
52 `)
53 }