kubeflow / notebooks

Kubeflow Notebooks lets you run web-based development environments on your Kubernetes cluster by running them inside Pods.
Apache License 2.0
18 stars 20 forks source link

test(ws): add safety prompt for E2E test execution #28

Closed Adembc closed 3 months ago

Adembc commented 4 months ago

This PR enhances the safety of running make test-e2e by implementing a confirmation prompt.

Why is this important?

The make test-e2e command executes tests on the current Kubernetes cluster. This can potentially disrupt a production environment, as the tests include cleanup operations such as deleting cert-manager after completion.

What changes were made?

  1. Added a confirmation prompt before test execution:

    • Displays the current Kubernetes cluster context
    • Asks for user confirmation to proceed
  2. Implemented a bypass option for CI/CD pipelines:

    • Set environment variable KUBEFLOW_TEST_PROMPT=FALSE to skip the prompt
    • The variable is case-insensitive (e.g., "FALSE", "false", or "False" are all valid)
  3. User confirmation:

    • Accepts "yes" or "y" (case-insensitive) to proceed with the tests
    • Any other input will abort the operation
google-oss-prow[bot] commented 3 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: thesuperzapper

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/kubeflow/notebooks/blob/notebooks-v2/OWNERS)~~ [thesuperzapper] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
thesuperzapper commented 3 months ago

/lgtm