This document contains a simple preliminary description of testcases on BookmarkEntry interface of Webclient API.

- Tests on getProperties() method
- Tests on isFolder() method
- Tests on insert(MutableTreeNode, int) method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on remove(int) method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on remove(MutableTreeNode) method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on removeFromParent() method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on setParent(MutableTreeNode) method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on setUserObject method (inherited from javax.swing.tree.MutableTreeNode)
- Tests on children() method (inherited from javax.swing.tree.TreeNode)
- Tests on getAllowsChildren() method (inherited from javax.swing.tree.TreeNode)
- Tests on getChildAt(int) method (inherited from javax.swing.tree.TreeNode)
- Tests on getChildCount() method (inherited from javax.swing.tree.TreeNode)
- Tests on getIndex(TreeNode) method (inherited from javax.swing.tree.TreeNode)
- Tests on getParent() method (inherited from javax.swing.tree.TreeNode)
- Tests on isLeaf() method (inherited from javax.swing.tree.TreeNode)

## 1. Tests on getProperties() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getProperties:0 | Method gets properties from bookmarkEntry which is recieved via TreeModel | Method returns correct properties
basic/api/BookmarkEntry_getProperties:1 | Method gets properties from bookmarkEntry which is recieved via newBookmarkEntry | Method returns correct properties
basic/api/BookmarkEntry_getProperties:2 | Method gets properties from bookmarkEntry which is recieved via newBookmarkFolder | Method returns correct properties

## 2. Tests on isFolder() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_isFolder:0 | Method checks bookmarkEntry recieved via newBookmarkEntry | Method returns false
basic/api/BookmarkEntry_isFolder:1 | Method checks bookmarkEntry recieved via newBookmarkFolder | Method returns true

## 3. Tests on insert(MutableTreeNode child, int index) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_insert:0 | Method adds NULL child to the receiver | Browser doesn't crashed
basic/api/BookmarkEntry_insert:1 | Method adds correct child to the receiver at index | Child is added
basic/api/BookmarkEntry_insert:2 | Method adds correct child to the receiver at index=0 | Browser doesn't crashed
basic/api/BookmarkEntry_insert:3 | Method adds correct child to the receiver at index=-2147483648 | Browser doesn't crashed
basic/api/BookmarkEntry_insert:4 | Method adds correct child to the receiver at index=2147483647 | Browser doesn't crashed

## 4. Tests on remove(int index) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_remove_1:0 | Method removes the child at existed index from the receiver. | Child is removed
basic/api/BookmarkEntry_remove_1:1 | Method removes the child at index=0 from the receiver. | Browser doesn't crashed
basic/api/BookmarkEntry_remove_1:2 | Method removes the child at index=-2147483648 from the receiver. | Browser doesn't crashed
basic/api/BookmarkEntry_remove_1:3 | Method removes the child at index=2147483647 from the receiver. | Browser doesn't crashed

## 5. Tests on remove(MutableTreeNode node) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_remove_2:0 | Method removes the NULL node from the receiver. | Browser doesn't crashed
basic/api/BookmarkEntry_remove_2:1 | Method removes the existed node from the receiver. | Child is removed

## 6. Tests on removeFromParent() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_removeFromParent:0 | Method removes the receiver from its parent=NULL. | Browser doesn't crashed
basic/api/BookmarkEntry_removeFromParent:1 | Method Removes the receiver from its correct parent. | Reciever is removed

## 7. Tests on setParent(MutableTreeNode newParent) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_setParent:0 | Method sets the parent of the receiver to newParent=NULL. | Browser doesn't crashed
basic/api/BookmarkEntry_setParent:1 | Method sets the parent of the receiver to correct newParent. | newParent is set

## 8. Tests on setUserObject(Object object) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_setUserObject:0 | Method resets the user object of the receiver to object=NULL. | Browser doesn't crashed
basic/api/BookmarkEntry_setUserObject:1 | Method resets the user object of the receiver to correct object. | The user object is reseted

## 9. Tests on children() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_children:0 | Method returns the children of the bookmarkFolder as an Enumeration. | Correct Enumeration object is returned.
basic/api/BookmarkEntry_children:1 | Method returns the children of the bookmarkEntry as an Enumeration. | Browser doesn't crashed

## 10. Tests on getAllowsChildren() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getAllowsChildren:0 | Method returns boolean result for the reciever=bookmarkFolder. | Result is true.
basic/api/BookmarkEntry_getAllowsChildren:1 | Method returns boolean result for the reciever=bookmarkEntry. | Result is false.

## 11. Tests on getChildAt(int index) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getChildAt:0 | Method tries to return the child of the bookmarkEntry. | Browser doesn't crashed
basic/api/BookmarkEntry_getChildAt:1 | Method returns the child at correct index. | Child is returned.
basic/api/BookmarkEntry_getChildAt:2 | Method tries to return the child at index=0. | Browser doesn't crashed
basic/api/BookmarkEntry_getChildAt:3 | Method tries to return the child at index=-2147483648. | Browser doesn't crashed
basic/api/BookmarkEntry_getChildAt:4 | Method tries to return the child at index=2147483647. | Browser doesn't crashed

## 12. Tests on getChildCount() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getChildCount:0 | Method returns the number of children the bookmarkFolder contains. | Correct number is returned.
basic/api/BookmarkEntry_getChildCount:1 | Method returns the number of children the bookmarkEntry contains. | Browser doesn't crashed

## 13. Tests on getIndex(TreeNode node) method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getIndex:0 | Method returns the index of node in the bookmarkFolder children. | Correct number is returned.
basic/api/BookmarkEntry_getIndex:1 | Method returns the index of node in the bookmarkEntry children. | Browser doesn't crashed
basic/api/BookmarkEntry_getIndex:2 | Method returns the index of node=NULL in the bookmarkFolder children. | Browser doesn't crashed
basic/api/BookmarkEntry_getIndex:3 | Method returns the index of node=bookmarkFolder in the bookmarkFolder children. | Browser doesn't crashed
basic/api/BookmarkEntry_getIndex:4 | Method returns the index of incorrect node in the bookmarkFolder children. | Browser doesn't crashed

## 14. Tests on getParent() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_getParent:0 | Method returns the parent node of the reciever=bookmarkFolder, which has no parent. | Browser doesn't crashed
basic/api/BookmarkEntry_getParent:1 | Method returns the parent node of the reciever=bookmarkFolder, which has a parent. | Correct parent is returned.
basic/api/BookmarkEntry_getParent:2 | Method returns the parent node of the reciever=bookmarkEntry, which has no parent. | Browser doesn't crashed
basic/api/BookmarkEntry_getParent:3 | Method returns the parent node of the reciever=bookmarkEntry, which has a parent. | Correct parent is returned.

## 15. Tests on isLeaf() method.

Test ID | Action | Expected Result
basic/api/BookmarkEntry_isLeaf:0 | Method returns true if reciever=bookmarkFolder is a leaf. | True is returned.
basic/api/BookmarkEntry_isLeaf:1 | Method returns true if reciever=bookmarkEntry is a leaf. | False is returned.