Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 337365 - Two failures for JPA-SRG with changeTracking weaving is false
Summary: Two failures for JPA-SRG with changeTracking weaving is false
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Guy Pelletier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 343014 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-02-16 16:30 EST by Kevin Yuan CLA
Modified: 2022-06-09 10:09 EDT (History)
3 users (show)

See Also:


Attachments
Proposed changes to correct one test (4.82 KB, patch)
2011-08-22 13:38 EDT, Guy Pelletier CLA
no flags Details | Diff
Proposed changes to correct second test (1.04 KB, patch)
2011-08-23 09:51 EDT, Guy Pelletier CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Yuan CLA 2011-02-16 16:30:44 EST
EclipseLink: trunk (2.3)
JDK: 1.6.0_23
DB: Oracle 11.1.0.7
When set "eclipselink.weaving.changetracking=false", and all other options keep default level. There are the following two tests failed with JPA-SRG (org.eclipse.persistence.testing.tests.jpa.advanced.EntityManagerJUnitTestSuite):

testGetReferenceUsedInUpdate:
=============================
junit.framework.AssertionFailedError: commit fetched object.
at org.eclipse.persistence.testing.tests.jpa.advanced.EntityManagerJUnitTestSuite.testGetReferenceUsedInUpdate(EntityManagerJUnitTestSuite.java:8404)
at org.eclipse.persistence.testing.framework.junit.JUnitTestCase.runBare(JUnitTestCase.java:503)

testWeaving:
============
junit.framework.AssertionFailedError: Object not weaved for ChangeTracker:Employee: null
at org.eclipse.persistence.testing.tests.jpa.advanced.EntityManagerJUnitTestSuite.internalTestWeaving(EntityManagerJUnitTestSuite.java:7860)
at org.eclipse.persistence.testing.tests.jpa.advanced.EntityManagerJUnitTestSuite.testWeaving(EntityManagerJUnitTestSuite.java:7825)
at org.eclipse.persistence.testing.framework.junit.JUnitTestCase.runBare(JUnitTestCase.java:503)
Comment 1 Tom Ware CLA 2011-07-18 13:43:37 EDT
moving targets of 2.3.0 bugs because 2.3.0 has shipped.
Comment 2 Guy Pelletier CLA 2011-08-22 13:38:52 EDT
Created attachment 201941 [details]
Proposed changes to correct one test

Patch fixes the testWeaving test
Comment 3 Guy Pelletier CLA 2011-08-23 09:51:51 EDT
Created attachment 202000 [details]
Proposed changes to correct second test

By turning the weaving for change tracking off, meaning using a deferred change tracking policy, the behavior is as expected and the test is incorrect. This update fixes the test.
Comment 4 Guy Pelletier CLA 2011-08-23 10:19:55 EDT
Changes have been submitted.

Reviewed: Tom Ware (patch 1), Gordon Yorke (patch 2)

Tests have been modified accordingly. No core changes, tests only.
Comment 5 Guy Pelletier CLA 2011-08-23 10:27:56 EDT
*** Bug 343014 has been marked as a duplicate of this bug. ***
Comment 6 Eclipse Webmaster CLA 2022-06-09 10:09:28 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink