blob: 9ff75116b54659a96e4b34bbd7be78b752f88446 [file] [log] [blame]
SeanCondon3c3d08f2022-05-27 11:39:58 +01001// SPDX-FileCopyrightText: 2022-present Intel Corporation
2//
3// SPDX-License-Identifier: Apache-2.0
4
5package tests
6
7import (
8 "testing"
9 "time"
10
11 "github.com/onosproject/helmit/pkg/helm"
12 "github.com/onosproject/helmit/pkg/input"
13 "github.com/onosproject/helmit/pkg/test"
14 "github.com/stretchr/testify/assert"
15)
16
17const aetherCharts = "https://charts.aetherproject.org/"
18
19// FabricUmbrellaSuite is the fabric-umbrella chart test suite
20type FabricUmbrellaSuite struct {
21 test.Suite
22 c *input.Context
23}
24
25// SetupTestSuite sets up the fabric-umbrella test suite
26func (s *FabricUmbrellaSuite) SetupTestSuite(c *input.Context) error {
27 s.c = c
28 return nil
29}
30
31// TestInstall tests installing the fabric-umbrella chart
32func (s *FabricUmbrellaSuite) TestInstall(t *testing.T) {
33 registry := s.c.GetArg("registry").String("")
34
35 onos := helm.Chart("fabric-umbrella", aetherCharts).
36 Release("fabric-umbrella").
37 WithTimeout(15*time.Minute).
38 Set("import.fabric-roc-gui.v0-1.enabled", false).
39 Set("import.fabric-adapter.v0-1.enabled", false).
40 Set("import.onos-cli.enabled", false).
41 Set("import.prometheus.fabric.enabled", false).
42 Set("fabric-roc-gui.service.type", "NodePort").
43 Set("global.image.registry", registry)
44 assert.NoError(t, onos.Install(true))
45}