theforeman/foreman — pull request #975 by ohadlevy (2013-10-24 08:10:52+00:00)
Title: [REFACTOR] fixes #2967 - refactored Fact Importer

Based on Dmitri Dolguikh original patch.

- renamed original fact_importer class to fact_parser class
- moved fact handling logic to its own fact_importer class
- fact importer now assumes single-value facts
- added a uniqueness constraint on fact_values table on fact_name_id and host_id
- added tests

replaces PR https://github.com/theforeman/foreman/pull/646