You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Yikun Jiang (Jira)" <ji...@apache.org> on 2020/04/09 08:29:00 UTC

[jira] [Assigned] (HIVE-23163) Class TrustDomainAuthenticationTest should be abstract

     [ https://issues.apache.org/jira/browse/HIVE-23163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yikun Jiang reassigned HIVE-23163:
----------------------------------

    Assignee: Yikun Jiang

> Class TrustDomainAuthenticationTest should be abstract
> ------------------------------------------------------
>
>                 Key: HIVE-23163
>                 URL: https://issues.apache.org/jira/browse/HIVE-23163
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Zhenyu Zheng
>            Assignee: Yikun Jiang
>            Priority: Major
>
> When running tests in pre-commit CI, the test parser will only identify test classes start with 'Test'
> [https://github.com/apache/hive/blob/d2163cbfb8bacf859fa8572e24c8533bb2dcb0f3/testutils/ptest2/src/main/java/org/apache/hive/ptest/execution/conf/UnitTestPropertiesParser.java#L406]
> But when running using `mvn test`, it will also parse classes such as '*Test.java':
> [http://maven.apache.org/plugins-archives/maven-surefire-plugin-2.12.4/examples/inclusion-exclusion.html]
> so for:
> [https://github.com/apache/hive/blob/d2163cbfb8bacf859fa8572e24c8533bb2dcb0f3/itests/hive-unit/src/test/java/org/apache/hive/service/auth/TrustDomainAuthenticationTest.java#L38]
> it will also be included in the test, for example:
> [https://builds.apache.org/view/H-L/view/Hive/job/Hive-linux-ARM-trunk/23/testReport/junit/org.apache.hive.service.auth/TrustDomainAuthenticationTest/testTrustedDomainAuthentication/]
> This is because that class TrustDomainAuthenticationTest is actually a parent class that does not have the parameters for init. The actual tests are its children classes like the rest in [https://builds.apache.org/view/H-L/view/Hive/job/Hive-linux-ARM-trunk/23/testReport/junit/org.apache.hive.service.auth/]
> they will pass actuall parameters for init: [https://github.com/apache/hive/blob/d2163cbfb8bacf859fa8572e24c8533bb2dcb0f3/itests/hive-unit/src/test/java/org/apache/hive/service/auth/TestTrustDomainAuthenticationBinary.java#L26] 
> we can make this class abstract so that it won't be included when running 'mvn test', like [https://github.com/apache/hive/blob/d2163cbfb8bacf859fa8572e24c8533bb2dcb0f3/itests/hive-unit/src/test/java/org/apache/hive/jdbc/AbstractJdbcTriggersTest.java#L54] 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)