[
https://issues.apache.org/jira/browse/SENTRY-1216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15260635#comment-15260635
]
Anne Yu commented on SENTRY-1216:
---------------------------------
The test method takes too long to finish. In a smaller box, the test takes even
longer. There are a couple of problems:
1. Each test is a single logical concept in the system.
http://artofunittesting.com/definition-of-a-unit-test/. One single test case
focuses on testing one issue.
2. If a big test case fails, it's hard to debug which feature it tested fails,
one usually has to debug the log. It also might because test data/context gets
polluted from previous testing actions.
We should advocate from now one, 1 test focuses on 1 issue; 1 test class won't
include many tests, in that case can finish within a couple of minutes (say no
more than 5 mins) from our pre-commit job.
> [unit test failure] disable sentry ha tests for now; add time out for each
> test class/method; fix trainsient junit time out issue
> ---------------------------------------------------------------------------------------------------------------------------------
>
> Key: SENTRY-1216
> URL: https://issues.apache.org/jira/browse/SENTRY-1216
> Project: Sentry
> Issue Type: Bug
> Components: Sentry
> Affects Versions: 1.8.0
> Reporter: Anne Yu
> Assignee: Anne Yu
> Fix For: 1.8.0
>
> Attachments: SENTRY-1216.1.patch, SENTRY-1216.2.patch,
> SENTRY-1216.3.patch, SENTRY-1216.4.patch, SENTRY-1216.5.patch
>
>
> Disable all sentry ha tests; after feature is implemented, enable all such
> tests;
> Also add time out for all test classes and methods; we shouldn't let jvm time
> out to kill process instead let junit to interrupt tests; so that we know
> which test(s) are failing because of time out; we need to fix these tests.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)