Fix bug in XFG_CONFIG handling
Fix deprecation warning when running tests