Implement and test Switch