remove some test code i had accidentally left in!

thought i was hitting this error case, so added a panic to test...
turns out I wasn't, but I forgot to remove the panic!
much simpler switch statement encoding.

thanks to e for pointing out this is possible (cool!).