Fixed various failing test cases

This pull request fixes the following test cases:

```
CanCollapseNodesAndGetSameResult
GitHub_461_DeleteNodesFromCustomNodeWorkspaceAfterCollapse
```