You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/05/05 13:00:34 UTC

[GitHub] [incubator-doris] wangshuo128 opened a new pull request, #9388: [refactor](test) Refactor FE unit test framework that starts a FE server.

wangshuo128 opened a new pull request, #9388:
URL: https://github.com/apache/incubator-doris/pull/9388

   # Proposed changes
   
   Issue Number: close #xxx
   
   Currently, we use `UtFrameUtils` to start a FE server in the FE unit test.  Each test class has to do some initialization and clean up stuff with the JUnit4 `@BeforeClass` and `@AfterClass` annotation. It's redundant and boring. Besides, almost all the API in `UtFrameUtils` has a `ConnectContext` parameter, which is not easy to use.
   
   This PR proposes to use an inherit-manner, i.e., wrap all the common logic in base class `TestWithFeService`, leveraging the 
   JUnit5 `@BeforeAll` and `@AfterAll` annotation to narrow down the setup and cleanup lifestyle to each test class instance. At the same time, the derived concrete test class could directly use utility methods inherited from the base class, without calling a util class and passing a `ConnectContext` argument.
   
   `UtFrameUtils` and `DorisAssert`  are marked as deprecated. We could remove these two classes if this refactor works well for a time.
   
   ## Problem Summary:
   
   Describe the overview of changes.
   
   ## Checklist(Required)
   
   1. Does it affect the original behavior: no
   2. Has unit tests been added: no
   3. Has document been added or modified: no
   4. Does it need to update dependencies: yes, bump up the JUnit version from 4.12 to 5.8.4
   5. Are there any changes that cannot be rolled back: no
   
   ## Further comments
   
   If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [incubator-doris] morningman merged pull request #9388: [refactor](test) Refactor FE unit test framework that starts a FE server.

Posted by GitBox <gi...@apache.org>.
morningman merged PR #9388:
URL: https://github.com/apache/incubator-doris/pull/9388


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [incubator-doris] wangshuo128 commented on pull request #9388: [refactor](test) Refactor FE unit test framework that starts a FE server.

Posted by GitBox <gi...@apache.org>.
wangshuo128 commented on PR #9388:
URL: https://github.com/apache/incubator-doris/pull/9388#issuecomment-1120151546

   This RP is ready to review, mind taking a look?  I think this refactoring would help to simplify the code in FE unit test. 
   cc @EmmyMiao87 @morningman  Thanks~


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [incubator-doris] github-actions[bot] commented on pull request #9388: [refactor](test) Refactor FE unit test framework that starts a FE server.

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #9388:
URL: https://github.com/apache/incubator-doris/pull/9388#issuecomment-1120209814

   PR approved by at least one committer and no changes requested.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [incubator-doris] github-actions[bot] commented on pull request #9388: [refactor](test) Refactor FE unit test framework that starts a FE server.

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #9388:
URL: https://github.com/apache/incubator-doris/pull/9388#issuecomment-1120209816

   PR approved by anyone and no changes requested.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org