Skip to content

Commit

Permalink
multi kind test 8
Browse files Browse the repository at this point in the history
  • Loading branch information
bartam1 committed Jul 25, 2023
1 parent ef7eacd commit fbf9a91
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 6 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/e2e-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ on:
jobs:
build:
runs-on: ubuntu-latest
permissions:
checks: write
pull-requests: write

steps:
- name: Set up Go
Expand Down Expand Up @@ -46,10 +49,12 @@ jobs:
kind_cluster_name: kind3
kind_k8s_version: v1.23.13

- name: run tests
- name: Run E2E tests
env:
KUBECONFIG: ${{ steps.setup-kind.outputs.kubeconfig }}
TEST_STRATEGY: complete
MAX_TIMEOUT: "30m"


run: |
go work init
Expand All @@ -60,7 +65,6 @@ jobs:
uses: EnricoMi/publish-unit-test-result-action/composite@master
if: always()
with:
json_file: e2e_result.json
commit: ${{ github.event.workflow_run.head_sha }}
report_individual_runs: "true"
check_name: "E2E test report"
Expand Down
10 changes: 7 additions & 3 deletions tests/e2e/pkg/tests/tests.go
Original file line number Diff line number Diff line change
Expand Up @@ -360,15 +360,19 @@ func newK8sClusterInfo(kubectlOptions k8s.KubectlOptions) (K8sClusterInfo, error
// TODO (marbarta): placeholder to get retrieve cluster information from kubeconfig
version, err := k8s.GetKubernetesClusterVersionWithOptionsE(GinkgoT(), &kubectlOptions)
if err != nil {
return K8sClusterInfo{}, err
return K8sClusterInfo{}, fmt.Errorf("could not get K8s cluster version: %w", err)
}
kubeSystemNS, err := k8s.GetNamespaceE(GinkgoT(), &kubectlOptions, "kube-system")
if err != nil {
return K8sClusterInfo{}, err
return K8sClusterInfo{}, fmt.Errorf("could not get K8s cluster UUID: %w", err)
}
nodes, err := k8s.GetNodesE(GinkgoT(), &kubectlOptions)
if err != nil {
return K8sClusterInfo{}, fmt.Errorf("could not get K8s cluster node count: %w", err)
}

return K8sClusterInfo{
workerCount: 3,
workerCount: len(nodes),
multiAZ: false,
clusterID: string(kubeSystemNS.UID),
provider: "testProvider",
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/test_install.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
)

var testCaseInstall = tests.TestCase{
TestDuration: 7 * time.Minute,
TestDuration: 4 * time.Minute,
TestName: "Install TestCase",
TestFn: testInstall,
}
Expand Down

0 comments on commit fbf9a91

Please sign in to comment.