collect_hw_data method was in a wrong namespace

(misplaced "end" statement)

- added a test for it
Merge pull request #17 from yast/collect_hw_data_fix

collect_hw_data method was in a wrong namespace