inner classes resolving + tests