From lkuskov at openjdk.org Mon Aug 4 21:57:58 2025 From: lkuskov at openjdk.org (Leonid Kuskov) Date: Mon, 4 Aug 2025 21:57:58 GMT Subject: RFR: 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing Message-ID: [CODETOOLS-7904057](https://bugs.openjdk.org/browse/CODETOOLS-7904057): com/sun/tdk/jcov/report/RecordContainerTest.java test is failing ------------- Commit messages: - CODETOOLS-7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing Changes: https://git.openjdk.org/jcov/pull/65/files Webrev: https://webrevs.openjdk.org/?repo=jcov&pr=65&range=00 Issue: https://bugs.openjdk.org/browse/CODETOOLS-7904057 Stats: 222 lines in 5 files changed: 210 ins; 2 del; 10 mod Patch: https://git.openjdk.org/jcov/pull/65.diff Fetch: git fetch https://git.openjdk.org/jcov.git pull/65/head:pull/65 PR: https://git.openjdk.org/jcov/pull/65 From shurailine at openjdk.org Mon Aug 11 14:30:34 2025 From: shurailine at openjdk.org (Alexandre Iline) Date: Mon, 11 Aug 2025 14:30:34 GMT Subject: RFR: 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing In-Reply-To: References: Message-ID: <87Olsy61ziu7ojatZuWzPAacHfNvDP4j9r71G1HDsCc=.1a39c8cd-a0b5-483b-8ca9-866c828399f2@github.com> On Mon, 4 Aug 2025 21:51:56 GMT, Leonid Kuskov wrote: > [CODETOOLS-7904057](https://bugs.openjdk.org/browse/CODETOOLS-7904057): com/sun/tdk/jcov/report/RecordContainerTest.java test is failing src/classes/com/sun/tdk/jcov/report/LineCoverage.java line 151: > 149: if (!wasHit && isHit) { > 150: ++covered; > 151: } else if (wasHit && !isHit) { I presume this may change the numbers for line coverage all around. Can you recommend any additional testing to the JCov users, such as myself, to make sure the reports are still valid. Or is this such a corner case so that we, the users of JCov, should not worry? ------------- PR Review Comment: https://git.openjdk.org/jcov/pull/65#discussion_r2266953730 From shurailine at openjdk.org Mon Aug 11 14:35:28 2025 From: shurailine at openjdk.org (Alexandre Iline) Date: Mon, 11 Aug 2025 14:35:28 GMT Subject: RFR: 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing In-Reply-To: References: Message-ID: On Mon, 4 Aug 2025 21:51:56 GMT, Leonid Kuskov wrote: > [CODETOOLS-7904057](https://bugs.openjdk.org/browse/CODETOOLS-7904057): com/sun/tdk/jcov/report/RecordContainerTest.java test is failing src/classes/com/sun/tdk/jcov/report/MethodCoverage.java line 66: > 64: */ > 65: public MethodCoverage(DataMethod method, boolean isJavapCoverage) { > 66: this(method, isJavapCoverage, null, null); While I appreciate this change, let's perhaps not push unrelated changes in the future? Such habit (of including unrelated changes in the commit) makes reviewing a lot harder and may (and have had) lead to bug escapes. This time it's OK as the change does not alter the code behavior. ------------- PR Review Comment: https://git.openjdk.org/jcov/pull/65#discussion_r2266973745 From lkuskov at openjdk.org Mon Aug 11 17:27:34 2025 From: lkuskov at openjdk.org (Leonid Kuskov) Date: Mon, 11 Aug 2025 17:27:34 GMT Subject: RFR: 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing In-Reply-To: <87Olsy61ziu7ojatZuWzPAacHfNvDP4j9r71G1HDsCc=.1a39c8cd-a0b5-483b-8ca9-866c828399f2@github.com> References: <87Olsy61ziu7ojatZuWzPAacHfNvDP4j9r71G1HDsCc=.1a39c8cd-a0b5-483b-8ca9-866c828399f2@github.com> Message-ID: <1Dp5HFgIxq67WG_5zt9CE8_asU-8bL-SJRTZRAIjuJI=.bad2fe77-00bf-474f-ba82-7a6a595dd7b8@github.com> On Mon, 11 Aug 2025 14:27:38 GMT, Alexandre Iline wrote: >> [CODETOOLS-7904057](https://bugs.openjdk.org/browse/CODETOOLS-7904057): com/sun/tdk/jcov/report/RecordContainerTest.java test is failing > > src/classes/com/sun/tdk/jcov/report/LineCoverage.java line 151: > >> 149: if (!wasHit && isHit) { >> 150: ++covered; >> 151: } else if (wasHit && !isHit) { > > I presume this may change the numbers for line coverage all around. Can you recommend any additional testing to the JCov users, such as myself, to make sure the reports are still valid. Or is this such a corner case so that we, the users of JCov, should not worry? The jcov report does not show how many times a code line was hit, so we just need to register that it happened without paying attention to the numbers. The report initially had this unhandled issue. To verify the fix, I compared the Java sources and javap outputs manually - no issues were detected. A unit test has been added. > src/classes/com/sun/tdk/jcov/report/MethodCoverage.java line 66: > >> 64: */ >> 65: public MethodCoverage(DataMethod method, boolean isJavapCoverage) { >> 66: this(method, isJavapCoverage, null, null); > > While I appreciate this change, let's perhaps not push unrelated changes in the future? Such habit (of including unrelated changes in the commit) makes reviewing a lot harder and may (and have had) lead to bug escapes. This time it's OK as the change does not alter the code behavior. Agree, I just didn?t find an appropriate JBS issue to cover this cosmetic change. ------------- PR Review Comment: https://git.openjdk.org/jcov/pull/65#discussion_r2267491729 PR Review Comment: https://git.openjdk.org/jcov/pull/65#discussion_r2267497862 From lkuskov at openjdk.org Mon Aug 11 17:27:35 2025 From: lkuskov at openjdk.org (Leonid Kuskov) Date: Mon, 11 Aug 2025 17:27:35 GMT Subject: Integrated: 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing In-Reply-To: References: Message-ID: On Mon, 4 Aug 2025 21:51:56 GMT, Leonid Kuskov wrote: > [CODETOOLS-7904057](https://bugs.openjdk.org/browse/CODETOOLS-7904057): com/sun/tdk/jcov/report/RecordContainerTest.java test is failing This pull request has now been integrated. Changeset: 98a9a59a Author: Leonid Kuskov URL: https://git.openjdk.org/jcov/commit/98a9a59a95fd99d197d08f9d614dcdc6e0d99d64 Stats: 222 lines in 5 files changed: 210 ins; 2 del; 10 mod 7904057: com/sun/tdk/jcov/report/RecordContainerTest.java test is failing Reviewed-by: shurailine ------------- PR: https://git.openjdk.org/jcov/pull/65