Extracted Task class from MachineShopSimulator. All tests pass.