more tests and a first shot at a structure for nested groupings