Rename defineParams helper and add tests