Skip to content

Commit

Permalink
Add feature suite
Browse files Browse the repository at this point in the history
Signed-off-by: Artem Glazychev <artem.glazychev@xored.com>
  • Loading branch information
glazychev-art committed Jun 1, 2022
1 parent 3690acb commit 1edf331
Show file tree
Hide file tree
Showing 9 changed files with 54 additions and 31 deletions.
2 changes: 1 addition & 1 deletion .cloudtest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ statistics:
interval: 60 # 60 seconds for statistics
import:
- cloudtest/packet.yaml
- cloudtest/tests.yaml
- cloudtest/tests_default.yaml

retest: # Allow to do test re-run if some kind of failures are detected.
count: 2 # Allow 2 times to do restart
Expand Down
2 changes: 1 addition & 1 deletion .cloudtest_calico.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ statistics:
interval: 60 # 60 seconds for statistics
import:
- cloudtest/packet.yaml
- cloudtest/tests.yaml
- cloudtest/tests_calico.yaml

retest: # Allow to do test re-run if some kind of failures are detected.
count: 2 # Allow 2 times to do restart
Expand Down
4 changes: 2 additions & 2 deletions cloudtest/packet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ providers:
ssh-key: sshkey.pub # A key name relative to $(tempdir) or absolute
hardware-devices:
- name: "Master"
host-name: "SR-IOV-Master-${CLUSTER_NAME}"
host-name: "Master-${CLUSTER_NAME}"
os: "ubuntu_20_04"
billing-cycle: "hourly"
port-vlans:
eth1: 3000 # calico VLAN
eth3: 1044 # SR-IOV VLAN
- name: "Worker"
host-name: "SR-IOV-Worker-${CLUSTER_NAME}"
host-name: "Worker-${CLUSTER_NAME}"
os: "ubuntu_20_04"
billing-cycle: "hourly"
port-vlans:
Expand Down
12 changes: 12 additions & 0 deletions cloudtest/tests_calico.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
executions:
- name: "tests-calico"
env:
- ARTIFACTS_ARCHIVE=true
root: ./tests_calico/
timeout: 3600
cluster-count: 1
cluster-selector:
- packet
cluster-env:
- KUBECONFIG
2 changes: 1 addition & 1 deletion cloudtest/tests.yaml → cloudtest/tests_default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ executions:
- name: "tests"
env:
- ARTIFACTS_ARCHIVE=true
root: ./
root: ./tests_default/
timeout: 3600
cluster-count: 1
cluster-selector:
Expand Down
2 changes: 2 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ require (
github.com/stretchr/testify v1.7.0
gopkg.in/yaml.v2 v2.4.0 // indirect
)

replace github.com/networkservicemesh/integration-tests v0.0.0-20220527083134-10ba1d22f919 => github.com/glazychev-art/integration-tests v0.0.0-20220601103612-35cb9fb9e33d
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoD
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/glazychev-art/integration-tests v0.0.0-20220601103612-35cb9fb9e33d h1:CsEWZx1FIjZgNO8FJjM7ax7TPrfbQGclRyB5lC3YGi0=
github.com/glazychev-art/integration-tests v0.0.0-20220601103612-35cb9fb9e33d/go.mod h1:0o7WrzxlHEwnDSuZPEM1BnKd4hr7+akKgymoAoTTbv8=
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
Expand Down Expand Up @@ -158,8 +160,6 @@ github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8m
github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw=
github.com/networkservicemesh/gotestmd v0.0.0-20211116145945-871d2aaf07ab h1:/dIr8Nky77grI3s9Rc78eFH9M1Svobyj2XJBaKm27ts=
github.com/networkservicemesh/gotestmd v0.0.0-20211116145945-871d2aaf07ab/go.mod h1:8EWnekTRNX+NxBdTFE24WqUoM7SgJHbiafDBrIIdOmQ=
github.com/networkservicemesh/integration-tests v0.0.0-20220527083134-10ba1d22f919 h1:OzC7AdvAoQ4KQljC2ZPBRFEwYRi9M2fsk6toSClu/QY=
github.com/networkservicemesh/integration-tests v0.0.0-20220527083134-10ba1d22f919/go.mod h1:0o7WrzxlHEwnDSuZPEM1BnKd4hr7+akKgymoAoTTbv8=
github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
Expand Down
28 changes: 4 additions & 24 deletions main_test.go → tests_calico/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,31 +19,11 @@ package main_test
import (
"testing"

"github.com/stretchr/testify/suite"
"github.com/networkservicemesh/integration-tests/suites/basic"

"github.com/networkservicemesh/integration-tests/suites/heal"
"github.com/networkservicemesh/integration-tests/suites/memory"
"github.com/networkservicemesh/integration-tests/suites/multiforwarder"
"github.com/networkservicemesh/integration-tests/suites/observability"
"github.com/networkservicemesh/integration-tests/suites/sriov"
"github.com/stretchr/testify/suite"
)

func TestMemory(t *testing.T) {
suite.Run(t, new(memory.Suite))
}

func TestSRIOV(t *testing.T) {
suite.Run(t, new(sriov.Suite))
}

func TestMultiForwarder(t *testing.T) {
suite.Run(t, new(multiforwarder.Suite))
}

func TestHeal(t *testing.T) {
suite.Run(t, new(heal.Suite))
}

func TestRunObservabilitySuite(t *testing.T) {
suite.Run(t, new(observability.Suite))
func TestFeatureSuite(t *testing.T) {
suite.Run(t, new(basic.Suite))
}
29 changes: 29 additions & 0 deletions tests_default/main_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// Copyright (c) 2020-2022 Doc.ai and/or its affiliates.
//
// SPDX-License-Identifier: Apache-2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at:
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package main_test

import (
"testing"

"github.com/stretchr/testify/suite"

"github.com/networkservicemesh/integration-tests/suites/features"
)

func TestFeatureSuite(t *testing.T) {
suite.Run(t, new(features.Suite))
}

0 comments on commit 1edf331

Please sign in to comment.