Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mode 1396 Tck Compatibility Updates #357

Merged
merged 22 commits into from Apr 23, 2012
Merged

Conversation

hchiorean
Copy link
Member

Updated & fixed some issues in order to make MS fully TCK compatible. The suite class which holds the tests is JcrTckTest.

There still are open issues, which have marked as TODOs with appropriate comments in the code. The issues are linked with dependencies from https://issues.jboss.org/browse/MODE-1396.

Horia Chiorean added 22 commits April 2, 2012 13:52
…e so that canSetProperty methods can work without a user session parameter
- fixed iterator behaviour (exposed by level 1 tck test)
- changed PathNotFound with ItemNotFound
- avoided possible NPE
- changed nodes should be copied, not use the same reference
- added missing exception
-added support for determining, in case of a node.save, whether nodes have been modified outside the hierarchy of the node
-added check on session.move, for SNS support under the destination's parent
-added checks, in writableSessionCache.save, for the case when nodes have been removed by another transaction and a preSave operation is attempted
-added some expected exception conversions
-fixed getChangedNodesAtOrBelow
-added check for changing existing protected properties
…nd reordering at the end of the children list

This has been implemented as part of MODE-1396, the Tck Level 2 tests
- added compacting of null values for multi-valued properties
- added check for mixed value types for multi-valued properties
- added expected javax.jcr.ValueFormatException
- fixed NPEs when null values are present in an array of values
… full key string for "normal" nodes and only the identifier part for root nodes.
- fixed string value for identifier paths
- added "abstract" validation on node.setPrimaryType
- updated UUID & reference behavior on import so that existing nodes can be found during import
- cleaned up child node definition validation
- when importing an node for which a new key is created and which has an explicit baseVersion and versionHistory reference properties, the code tried to create a new version history hierarchy instead of linking the existing one
- fixed NPE caused by an empty baseVersionKeys field when importing via the workspace
- updated Jcr pre-save to set the modified and created properties only if they haven't been changed externally (like is the case of an import)
…for locks, so that they match what the TCK expects. To be more precise, only the isDeep and lockOwner property events should be fired.
- fixed algorithm for detecting changes at/below path
- fixed test node type for node which don't allow children (mode:namespace was used previously, but that caused SystemNodes to be created)
- added missing node moved case handling, when the move was a rename
- fixed getVersionByLabel (was not using the fully qualified label name)
- fixed setting & updating of successors and predecessors (root node was not taken into account & no value was being set when the mix:versionable was applied for the first time)
- added & refactored session state validation in the JcrVersionManager
- fixed children names and reordering  when restoring versioned children
 -update the JcrTckTest class to be able to exclude only specific tests from the TCK, instead of entire test cases
…rst, otherwise if the parents are removed, we can't determine the children's path
 - added missing handling on lock token in JcrLockManager
 - added exception conversion - AccessDenied to LockException
 - changed events & lock properties handling on locked nodes: the RepositoryLockManager sets the isDeep & owner properties, so that events are properly fired for locked nodes. Removed previous "hack" regarding event handling and also the code which changes the document "behind the scenes"
 - changed getLockTokens to return only the open scoped locks (Jcr spec)
 - bumped up testing memory size because of an OOM exception on JcrWritingTest and the LuceneIndexWriter
…en setting a property value from a read-only session
@rhauch rhauch merged commit b1068b8 into ModeShape:master Apr 23, 2012
@rhauch
Copy link
Contributor

rhauch commented Apr 23, 2012

All these changes and corrections were spot on. Fantastic work, @hchiorean!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants