Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add feature suite #283

Merged
merged 1 commit into from
Jun 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.16

require (
github.com/googleapis/gnostic v0.5.1 // indirect
github.com/networkservicemesh/integration-tests v0.0.0-20220527083134-10ba1d22f919
github.com/networkservicemesh/integration-tests v0.0.0-20220602154027-8f75f9feabdc
github.com/stretchr/testify v1.7.0
gopkg.in/yaml.v2 v2.4.0 // indirect
)
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,8 @@ 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/networkservicemesh/integration-tests v0.0.0-20220602154027-8f75f9feabdc h1:gt3w2+ibjPglukZSsk6AHOqvvwjyx/jpxX71i2Pf1EE=
github.com/networkservicemesh/integration-tests v0.0.0-20220602154027-8f75f9feabdc/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
67 changes: 67 additions & 0 deletions tests_calico/main_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
// 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"
"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"
)

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))
}

// Disabled tests:
// TestMutually_aware_nses - https://github.com/networkservicemesh/integration-k8s-kind/issues/627
type featuresSuite struct {
features.Suite
}

func (s *featuresSuite) BeforeTest(suiteName, testName string) {
if testName == "TestMutually_aware_nses" {
s.T().Skip()
}
s.Suite.BeforeTest(suiteName, testName)
}

func TestRunFeatureSuiteCalico(t *testing.T) {
suite.Run(t, new(featuresSuite))
}
5 changes: 5 additions & 0 deletions main_test.go → tests_default/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (

"github.com/stretchr/testify/suite"

"github.com/networkservicemesh/integration-tests/suites/features"
"github.com/networkservicemesh/integration-tests/suites/heal"
"github.com/networkservicemesh/integration-tests/suites/memory"
"github.com/networkservicemesh/integration-tests/suites/multiforwarder"
Expand All @@ -47,3 +48,7 @@ func TestHeal(t *testing.T) {
func TestRunObservabilitySuite(t *testing.T) {
suite.Run(t, new(observability.Suite))
}

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