Refs #5111 - updated tests

- test nested collections with variable length
- fixed structure of the test cases