You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Chenguang Zhu (JIRA)" <ji...@apache.org> on 2018/01/25 04:26:00 UTC
[jira] [Created] (MNG-6349) Incorrect incremental test compilation
Chenguang Zhu created MNG-6349:
----------------------------------
Summary: Incorrect incremental test compilation
Key: MNG-6349
URL: https://issues.apache.org/jira/browse/MNG-6349
Project: Maven
Issue Type: Bug
Components: core
Affects Versions: 3.5.2, 3.5.0
Environment: Ubuntu 16.04, Ubuntu 17.10
Reporter: Chenguang Zhu
Attachments: maven_bug_incremental_compile.zip
Summary: Consder the following simple project. There are three
classes, A, C (which extends A), and T (which is a test class). Class
A has method m(int), class C has method m(long), and test invokes m
with int value. If we run 'mvn test' the test passes. If we then
remove "extends A" from C and run 'mvn test' again, the run fails with
'NoSuchMethodError'. We noticed in the output that the test class was
not recompiled (which should likely have been done).
Steps to Reproduce: Run the bash script ./s provided in this
directory. The script (1) runs mvn test, (2) removes 'extends A' from
class C, and (3) runs mvn test again.
Expected Results: p.CTest fails in the second execution. Failed tests:
test(p.CTest): expected:<0> but was:<1>.
Actual Results: p.CTest has an error in the second execution.
java.lang.NoSuchMethodError: p.C.m(I)I.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)