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

don't run serial tests any more when FOCUS is specified #16846

Closed
wants to merge 1 commit into from

Conversation

jim-minter
Copy link
Contributor

@jim-minter jim-minter commented Oct 12, 2017

follow up from #16842, may also solve the same issue as #16806

@openshift-ci-robot openshift-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Oct 12, 2017
@jim-minter
Copy link
Contributor Author

@smarterclayton @bparees @miminar let's try this?

@bparees
Copy link
Contributor

bparees commented Oct 12, 2017

we can't do this by itself, it means our nightly extended test jobs won't run the [Serial] tests. (we use focus to run all the [builds] and [image_ecosystem] tests and some of them are marked [Serial])

if there's a plan for how $FOCUS + [Serial] tests are going to be run, we'll need to include it in this PR.

@smarterclayton
Copy link
Contributor

Not supported. Find a different solution. The only serial tests should be those that need while cluster access. Are you thinking of disruptive tests?

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Oct 12, 2017
@smarterclayton
Copy link
Contributor

"Whole"

@openshift-merge-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jim-minter, smarterclayton

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

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 12, 2017
@smarterclayton
Copy link
Contributor

Or maybe slow tests?

@bparees
Copy link
Contributor

bparees commented Oct 12, 2017

i'm thinking of tests like our build test that confirms that the next build is started immediately after the last one. When it's run on an overloaded parallel environment, the timings become impossible to confirm. When it's run serially, it's rock solid and we ensure that we have not regressed the "next build starts when the previous build finishes" behavior.

And merging a PR that immediately disables existing tests strikes me as the wrong answer and is just asking for regressions.

This also makes it impossible run those tests locally, which is kinda the whole point of FOCUS in the first place.

At a minimum, anything currently marked [Serial] should be marked conformance so they continue to get run until we have an actual solution to this problem.

@bparees
Copy link
Contributor

bparees commented Oct 12, 2017

i'm also reasonably sure this behavior is going to confuse the heck out of someone in the future when they attempt to do a FOCUS on a [Serial] test and it won't run.

@bparees
Copy link
Contributor

bparees commented Oct 13, 2017

talked with @smarterclayton about this some more, sounds like he is going to create a serial bucket that runs all the serial tests. I can live w/ that, though i still think this will confuse people trying to run individual serial tests locally via FOCUS.

My other suggestion would be to run with something like --ginkgo.focus=$FOCUS.*?[Serial]|[Serial].*?$FOCUS for the serial portion. It won't work with 100% of regexes people might use, but it should work for most of them.

@miminar
Copy link

miminar commented Oct 13, 2017

i'm also reasonably sure this behavior is going to confuse the heck out of someone in the future when they attempt to do a FOCUS on a [Serial] test and it won't run.

👍

This renders most of the tests in extended_image_registry job untestable - both locally and in CI.

Not supported. Find a different solution. The only serial tests should be those that need while cluster access. Are you thinking of disruptive tests?

In case of serial registry tests - several tests apply different registry configuration (read-only on/off acceptschema2 on/off etc.), which restarts the registry. Such tests cannot be run in parallel with other tests interacting with registry.

@openshift-bot
Copy link
Contributor

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-merge-robot
Copy link
Contributor

/test all [submit-queue is verifying that this PR is safe to merge]

@smarterclayton
Copy link
Contributor

smarterclayton commented Oct 13, 2017 via email

@openshift-ci-robot
Copy link

openshift-ci-robot commented Oct 13, 2017

@jim-minter: The following test failed, say /retest to rerun them all:

Test name Commit Details Rerun command
ci/openshift-jenkins/extended_conformance_install_update 3b7138c link /test extended_conformance_install_update

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@bparees
Copy link
Contributor

bparees commented Oct 13, 2017

I'd rather not have that complexity. Avoid making tests serial, and maybe we'll add a serial job to PR that people can focus.

Seems like @miminar gave a pretty good reason for needing serial tests and prefixing/appending [Serial] does not seem that complex, especially compared to the other things that are being done to run our extended tests.

@bparees
Copy link
Contributor

bparees commented Oct 13, 2017

/hold
(we can't just disable all the registry tests w/o a plan)

@openshift-ci-robot openshift-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 13, 2017
@miminar
Copy link

miminar commented Oct 13, 2017

(we can't just disable all the registry tests w/o a plan)

We've just discussed this with @Kargakis. We can provide a custom script for this particular job in here: https://github.com/openshift/aos-cd-jobs/blob/master/sjb/config/test_cases/test_pull_request_origin_extended_image_registry.yml
that would invoke ginkgo directly to test exactly what we need.

@bparees
Copy link
Contributor

bparees commented Oct 13, 2017

We've just discussed this with @Kargakis. We can provide a custom script for this particular job in here: https://github.com/openshift/aos-cd-jobs/blob/master/sjb/config/test_cases/test_pull_request_origin_extended_image_registry.yml
that would invoke ginkgo directly to test exactly what we need.

still means it'll be harder to run the tests locally (you'll have to invoke ginkgo manually there too) but sure.

@miminar
Copy link

miminar commented Oct 13, 2017

still means it'll be harder to run the tests locally (you'll have to invoke ginkgo manually there too) but sure.

Yes, it's a workaround until the extended scripts will be generic enough to select what needs to be run and what not.

@miminar
Copy link

miminar commented Oct 13, 2017

We can provide a custom script for this particular job in here

Initial untested version is here: openshift-eng/aos-cd-jobs#729

@smarterclayton
Copy link
Contributor

Let's just create a serial pr job that supports focus. Let's stop hacking around bad decisions we made years ago.

Also, any serial registry test should be installing its own registry and hacking that. Updating the core registry is a bad pattern. I'm not aware of any reason why you can't spin up the registry image and point it as openshift. Should work fine.

@bparees
Copy link
Contributor

bparees commented Oct 13, 2017

Let's just create a serial pr job that supports focus. Let's stop hacking around bad decisions we made years ago.

how do you propose to do that? is that not still going to be ginkgo.focus="$FOCUS.*[Serial]" ?

The whole challenge here is selecting the set of tests that contain both [Serial] and $FOCUS.

@stevekuznetsov
Copy link
Contributor

+100 to Ben's regex solution because it's simple and unblocks this. the underlying issues are:

  • if your test is serial you're doing something sub-optimally (not starting your own registry to test against, not validating controller logic with fake event stream etc
  • we should not try to tackle the test selection problem in bash
  • this "organic" script is out of hand

We should spend the time to tackle these top-down (change Ginkgo? remove serial tests?) but we should not allow that effort to roadblock running the current serial tests we have

@jim-minter
Copy link
Contributor Author

closing for #16919

@jim-minter jim-minter closed this Oct 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants