Added TargetFactory and tests for TargetFactory

Note though that the tests for TargetFactory will need to be expanded later when we are adding XML or other file reading formats.