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

[Bundle Build Break] Integration tests are run during build workflow #57

Closed
peternied opened this issue Sep 2, 2021 · 6 comments
Closed
Labels
bug Something isn't working untriaged v1.1.0

Comments

@peternied
Copy link
Member

Describe the bug
During the build workflow, script file here disables integration test with -DskipTests=true but integration tests are still running during the workflow.

Expected behavior
Integration tests should be disabled to prevent delays in built time for the OpenSearch distribution. Integration test should run in other workflow steps.

The build script should be updated to have the correct flags, see https://github.com/opensearch-project/opensearch-build/tree/main/bundle-workflow/scripts/components for more details on how distribution builds are triggered and can be modified.

@peternied peternied added bug Something isn't working Beta untriaged labels Sep 2, 2021
@peternied
Copy link
Member Author

Found when #56 was discovered, see that bug for a full execution logs.

@peternied peternied added v1.1.0 and removed Beta labels Sep 17, 2021
@peternied
Copy link
Member Author

Another build was blocked because of an integration test failure:

REPRODUCE WITH: ./gradlew ':opensearch-job-scheduler-spi:integTest' --tests "org.opensearch.jobscheduler.spi.utils.LockServiceIT.testRenewLock" -Dtests.seed=BD9E621F27BCF716 -Dtests.security.manager=false -Dtests.locale=en-IE -Dtests.timezone=Asia/Kathmandu -Druntime.java=14

org.opensearch.jobscheduler.spi.utils.LockServiceIT > testRenewLock FAILED
    com.carrotsearch.randomizedtesting.UncaughtExceptionError: Captured an uncaught exception in thread: Thread[id=29, name=opensearch[transport_client_external_0][listener][T#1], state=RUNNABLE, group=TGRP-LockServiceIT]
        at __randomizedtesting.SeedInfo.seed([BD9E621F27BCF716:184EAC40754E36A7]:0)

        Caused by:
        java.lang.AssertionError: Failed to release lock.
            at __randomizedtesting.SeedInfo.seed([BD9E621F27BCF716]:0)
            at org.junit.Assert.fail(Assert.java:88)
            at org.junit.Assert.assertTrue(Assert.java:41)
            at org.opensearch.jobscheduler.spi.utils.LockServiceIT.lambda$testRenewLock$63(LockServiceIT.java:488)

@peternied peternied changed the title [BUG] Integration tests are run during build workflow [Bundle Build Break] Integration tests are run during build workflow Sep 17, 2021
@bowenlan-amzn
Copy link
Member

@peternied
Copy link
Member Author

The root cause of this issue is that a failed build can hold up the organization, we should not signal a failure during the opensearch-build process for a distribution build if its a flaky test case.

@bowenlan-amzn The flaky test case does not seem to be addressed, has that been resolved in another issue or pull request?

@peternied peternied reopened this Apr 20, 2022
@bowenlan-amzn
Copy link
Member

I thought assemble resolves this issue, unless there's some concern of using it other than gradle build without running test tasks.

For not running test during ./gradlew build, the special thing in this repo I just checked is we have a test task called javaRestTest, it's actually similar to integTest in other plugin repo. ./gradlew build -x integTest -x javaRestTest -x test should disable all tests.

And yeah, you created a issue for the flaky test #56 😛, but we haven't got time to debug it.

@peternied
Copy link
Member Author

Thanks @bowenlan-amzn, sounds like #56 is the only follow up that is needed. Closing this issue out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working untriaged v1.1.0
Projects
None yet
Development

No branches or pull requests

2 participants