-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: ii2day <ji.li@daocloud.io>
- Loading branch information
ii2day
committed
Jul 13, 2023
1 parent
54abc3f
commit 43cd4a8
Showing
304 changed files
with
38,896 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# E2E Cases for AppHttpHealth | ||
|
||
| Case ID | Title | Priority | Smoke | Status | Other | | ||
|---------|-----------------------------------------------------------------------------|----------|-------|--------|-------------| | ||
| A00001 | Successfully http testing appHttpHealth method GET case | p1 | | done | | | ||
| A00002 | Failed http testing appHttpHealth due to status code case | p1 | | done | | | ||
| A00003 | Failed http testing appHttpHealth due to delay case | p1 | | done | | | ||
| A00004 | Successfully https testing appHttpHealth method GET case | p1 | | done | | | ||
| A00005 | Failed https testing appHttpHealth due to tls case | p1 | | done | | | ||
| A00006 | Successfully http testing appHttpHealth method PUT case | p1 | | done | | | ||
| A00007 | Successfully http testing appHttpHealth method POST With Body case | p1 | | done | | | ||
| A00008 | Successfully http testing appHttpHealth method HEAD case | p1 | | done | | | ||
| A00009 | Successfully http testing appHttpHealth method PATCH case | p1 | | done | | | ||
| A000010 | Successfully http testing appHttpHealth method OPTIONS case | p1 | | done | | | ||
| A000011 | After QPS is specified, the number of requests meets the requirements case | p1 | | done | | | ||
| A000012 | Successfully http testing appHttpHealth due to success rate case | p1 | | done | | | ||
| A000013 | Successfully https testing appHttpHealth method GET Protocol Http2 case | p1 | | done | | | ||
| A000014 | Report request count equal real request count case | p1 | | done | | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# E2E Cases for IP NetReach | ||
|
||
| Case ID | Title | Priority | Smoke | Status | Other | | ||
|---------|--------------------------------------------------------|----------|-------|--------|-------------| | ||
| B00001 | Successfully testing netReach case | p1 | | done | | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# E2E Cases for IP schedule | ||
|
||
| Case ID | Title | Priority | Smoke | Status | Other | | ||
|---------|-------------------------------------------------|----------|-------|--------|-------------| | ||
| C00001 | Successfully testing NetReach crontab case | p1 | | done | | | ||
| C00002 | Successfully testing AppHttpHealth crontab case | p1 | | done | | | ||
| C00003 | Successfully testing NetReach sample case | p1 | | done | | | ||
| C00004 | Successfully testing AppHttpHealth sample case | p1 | | done | | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
// Copyright 2023 Authors of kdoctor-io | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
package apphttphealth_test | ||
|
||
import ( | ||
"context" | ||
kdoctor_v1beta1 "github.com/kdoctor-io/kdoctor/pkg/k8s/apis/kdoctor.io/v1beta1" | ||
"github.com/kdoctor-io/kdoctor/test/e2e/common" | ||
. "github.com/onsi/ginkgo/v2" | ||
. "github.com/onsi/gomega" | ||
e2e "github.com/spidernet-io/e2eframework/framework" | ||
"github.com/spidernet-io/e2eframework/tools" | ||
v1 "k8s.io/api/core/v1" | ||
"k8s.io/apimachinery/pkg/runtime" | ||
"k8s.io/apimachinery/pkg/types" | ||
"testing" | ||
) | ||
|
||
func TestNetReach(t *testing.T) { | ||
RegisterFailHandler(Fail) | ||
RunSpecs(t, "AppHttpHealth Suite") | ||
} | ||
|
||
var frame *e2e.Framework | ||
|
||
var httpPort = 80 | ||
var httpsPort = 443 | ||
var bodyConfigMapName string | ||
var caSecret *v1.Secret | ||
var reportNum int | ||
|
||
var _ = BeforeSuite(func() { | ||
defer GinkgoRecover() | ||
var e error | ||
frame, e = e2e.NewFramework(GinkgoT(), []func(*runtime.Scheme) error{kdoctor_v1beta1.AddToScheme}) | ||
Expect(e).NotTo(HaveOccurred()) | ||
|
||
// test request body | ||
bodyConfigMapName = "kdoctor-test-body-" + tools.RandomName() | ||
cm := new(v1.ConfigMap) | ||
cm.SetName(bodyConfigMapName) | ||
cm.SetNamespace(common.TestNameSpace) | ||
body := make(map[string]string, 0) | ||
body["test1"] = "test1" | ||
body["test2"] = "test2" | ||
cm.Data = body | ||
e = frame.CreateConfigmap(cm) | ||
Expect(e).NotTo(HaveOccurred(), "create test body configmap") | ||
|
||
caSecret = new(v1.Secret) | ||
key := types.NamespacedName{ | ||
Name: common.KDoctorCaName, | ||
Namespace: common.TestNameSpace, | ||
} | ||
e = frame.KClient.Get(context.Background(), key, caSecret) | ||
Expect(e).NotTo(HaveOccurred(), "get kdoctor ca secret") | ||
|
||
ds, e := frame.GetDaemonSet(common.KDoctorAgentDSName, common.TestNameSpace) | ||
Expect(e).NotTo(HaveOccurred(), "get kdoctor-agent daemonset") | ||
reportNum = int(ds.Status.NumberReady) | ||
}) | ||
|
||
var _ = AfterSuite(func() { | ||
defer GinkgoRecover() | ||
_ = frame.DeleteConfigmap(bodyConfigMapName, common.TestNameSpace) | ||
}) |
Oops, something went wrong.