This revised patchset adds Rspec tests for the templates (very basic). @jayg: I've changed the local variable to an instance variable in the destroy action since I'm returning that data back to the client so it was needed. The mapping from /api/hardware_profiles to /hardware_profiles is temporary. It is needed to test the cli functionality. It can be removed later