Skip to content

Commit dbb7b35

Browse files
committed
test: remove nightly tests completely
this commit removes nightly tests completely because we don't need nightly tests anymore. nighlty tests were added to avoid rate limiting issue but as we moved to GHE we don't have rate limit issue anymore. Signed-off-by: Zaki Shaikh <zashaikh@redhat.com>
1 parent 10dd0b6 commit dbb7b35

7 files changed

Lines changed: 0 additions & 64 deletions

.github/workflows/e2e.yaml

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -505,26 +505,6 @@ jobs:
505505
run: |
506506
./hack/gh-workflow-ci.sh run_e2e_tests
507507
508-
- name: Run E2E Tests on nightly
509-
# This step still runs specifically for schedule or workflow_dispatch
510-
if: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
511-
env:
512-
NIGHTLY_E2E_TEST: "true"
513-
TEST_PROVIDER: ${{ matrix.provider }}
514-
TEST_BITBUCKET_CLOUD_TOKEN: ${{ secrets.BITBUCKET_CLOUD_TOKEN }}
515-
TEST_EL_WEBHOOK_SECRET: ${{ secrets.WEBHOOK_SECRET }}
516-
TEST_GITHUB_REPO_INSTALLATION_ID: ${{ vars.INSTALLATION_ID }}
517-
TEST_GITHUB_TOKEN: ${{ secrets.GH_APPS_TOKEN }}
518-
TEST_GITHUB_SECOND_TOKEN: ${{ secrets.TEST_GITHUB_SECOND_TOKEN }}
519-
TEST_GITHUB_SECOND_WEBHOOK_TOKEN: ${{ secrets.TEST_GITHUB_SECOND_WEBHOOK_TOKEN }}
520-
TEST_GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }}
521-
TEST_BITBUCKET_SERVER_TOKEN: ${{ secrets.BITBUCKET_SERVER_TOKEN }}
522-
TEST_BITBUCKET_SERVER_API_URL: ${{ secrets.BITBUCKET_SERVER_API_URL }}
523-
TEST_BITBUCKET_SERVER_WEBHOOK_SECRET: ${{ secrets.BITBUCKET_SERVER_WEBHOOK_SECRET }}
524-
TEST_GITHUB_SECOND_APPLICATION_ID: ${{ vars.TEST_GITHUB_SECOND_APPLICATION_ID }}
525-
run: |
526-
./hack/gh-workflow-ci.sh run_e2e_tests
527-
528508
- name: Collect logs
529509
if: ${{ always() }}
530510
env:

test/README.md

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -152,28 +152,6 @@ To clean up stale test projects (older than 7 days) left from previous runs:
152152

153153
If you need to update the golden files in the end-to-end test, add the `-update` flag to the [go test](https://pkg.go.dev/cmd/go#hdr-Test_packages) command to refresh those files. First, run it if you expect the test output to change (or for a new test), then run it again without the flag to ensure everything is correct.
154154

155-
## Running nightly tests
156-
157-
Some tests are set as nightly which mean not run on every PR, because exposing rate limitation often.
158-
We run those as nightly via github action on kind.
159-
160-
You can use `make test-e2e-nightly` if you want to run those manually as long
161-
as you have all the env variables set.
162-
163-
If you are writing a test targeting a nightly test you need to check for the env variable:
164-
165-
```go
166-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
167-
t.Skip("Skipping test since only enabled for nightly")
168-
}
169-
```
170-
171-
and maybe add to the test-e2e-nightly Makefile target to the -run argument :
172-
173-
```bash
174-
-run '(TestGithub|TestOtherPrefixOfTest)'
175-
```
176-
177155
## Continuous Integration (CI) with GitHub Actions
178156

179157
Our E2E tests are automatically run as part of our CI pipeline using GitHub Actions. This section explains how the CI process works, the components involved, and how to troubleshoot or extend it.
@@ -363,7 +341,6 @@ To add new provider tests:
363341
1. Create test files following the existing patterns
364342
2. Ensure proper naming convention to match the test category filters
365343
3. Update environment variables if needed
366-
4. For nightly-only tests, include the check for `NIGHTLY_E2E_TEST`
367344

368345
For infrastructure changes:
369346

test/github_pullrequest_oktotest_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,6 @@ import (
2121
)
2222

2323
func TestGithubGHEPullRequestOkToTest(t *testing.T) {
24-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
25-
t.Skip("Skipping test since only enabled for nightly")
26-
}
2724
ctx := context.TODO()
2825
g := &tgithub.PRTest{
2926
Label: "Github OkToTest comment",

test/github_pullrequest_retest_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,6 @@ import (
2121
// TestGithubGHEPullRequestGitopsCommentRetest will test the retest
2222
// functionality of a GitHub pull request.
2323
func TestGithubGHEPullRequestGitopsCommentRetest(t *testing.T) {
24-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
25-
t.Skip("Skipping test since only enabled for nightly")
26-
}
2724
ctx := context.Background()
2825
g := &tgithub.PRTest{
2926
Label: "Github retest comment",

test/github_pullrequest_test.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,6 @@ func TestGithubGHEPullRequest(t *testing.T) {
5555
}
5656

5757
func TestGithubGHEPullRequestMultiples(t *testing.T) {
58-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
59-
t.Skip("Skipping test since only enabled for nightly")
60-
}
6158
ctx := context.Background()
6259
g := &tgithub.PRTest{
6360
Label: "Github multiple PullRequest",
@@ -69,9 +66,6 @@ func TestGithubGHEPullRequestMultiples(t *testing.T) {
6966
}
7067

7168
func TestGithubGHEPullRequestMatchOnCEL(t *testing.T) {
72-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
73-
t.Skip("Skipping test since only enabled for nightly")
74-
}
7569
ctx := context.Background()
7670
g := &tgithub.PRTest{
7771
Label: "Github CEL Match",

test/github_pullrequest_test_comment_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@ import (
1818
)
1919

2020
func TestGithubGHEPullRequestTest(t *testing.T) {
21-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
22-
t.Skip("Skipping test since only enabled for nightly")
23-
}
2421
ctx := context.TODO()
2522
g := &tgithub.PRTest{
2623
Label: "Github test implicit comment",

test/github_scope_token_to_list_of_private_public_repos_test.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ import (
2929

3030
func TestGithubPullRequestScopeTokenToListOfRepos(t *testing.T) {
3131
t.Skip("Skipping test changing the global config map for now")
32-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
33-
t.Skip("Skipping test since only enabled for nightly")
34-
}
3532

3633
var remoteTaskURL, remoteTaskName string
3734
if os.Getenv("TEST_GITHUB_PRIVATE_TASK_URL") != "" {
@@ -55,9 +52,6 @@ func TestGithubPullRequestScopeTokenToListOfRepos(t *testing.T) {
5552

5653
func TestGithubPullRequestScopeTokenToListOfReposByGlobalConfiguration(t *testing.T) {
5754
t.Skip("Skipping test changing the global config map for now")
58-
if os.Getenv("NIGHTLY_E2E_TEST") != "true" {
59-
t.Skip("Skipping test since only enabled for nightly")
60-
}
6155

6256
var remoteTaskURL, remoteTaskName string
6357
if os.Getenv("TEST_GITHUB_PRIVATE_TASK_URL") != "" {

0 commit comments

Comments
 (0)