bugfix, add tests for show_profiles and dump_profiles()