First implementation of method switch with tests.