Add a test of encoding multiple spatial layers

This increases the coverage of the unit tests.