def test_job_configuration(self):
        "Test config.yaml job layout"
        self._load_config_fixture('config.yaml')
        self.start_server()

        self.assertFalse(self.worker_server.stopped())
        self.assertEqual(3, len(self.worker_server.jobs))

        expected_jobs = {
            'build:real-db-upgrade_nova_mysql': {
                "name": "build:real-db-upgrade_nova_mysql",
                "plugin": "real_db_upgrade",
                "runner_module_name": "turbo_hipster.task_plugins."
                                      "real_db_upgrade.task",
                "job_config": {
                    "name": "build:real-db-upgrade_nova_mysql",
                    "plugin": "real_db_upgrade",
                    "datasets_dir": "/home/josh/var/lib/turbo-hipster/datasets"
                },
            },
            'build:real-db-upgrade_nova_mysql_user_001': {
                "name": "build:real-db-upgrade_nova_mysql_user_001",
                "plugin": "real_db_upgrade",
                "runner_module_name": "turbo_hipster.task_plugins."
                                      "real_db_upgrade.task",
                "plugin_config": {
                    "name": "real_db_upgrade",
                    "datasets_dir": "/var/lib/turbo-hipster/datasets_user_001",
                    "function": "build:real-db-upgrade_nova_mysql_user_001",
                },
            },
            'build:some_shell_job': {
                "name": "build:some_shell_job",
                "plugin": "shell_script",
                "runner_module_name": "turbo_hipster.task_plugins."
                                      "shell_script.task",
                "job_config": {
                    "name": "build:some_shell_job",
                    "shell_script": "/dev/null",
                },
            },
        }

        for job_name, job in self.worker_server.jobs.items():
            self.assertEqual(expected_jobs[job_name]['name'],
                             job['name'])
            self.assertEqual(expected_jobs[job_name]['plugin'],
                             job['plugin'])
            if 'plugin_config' in job:
                self.assertEqual(expected_jobs[job_name]['plugin_config'],
                                 job['plugin_config'])
            if 'job_config' in job:
                self.assertEqual(expected_jobs[job_name]['job_config'],
                                 job['job_config'])
            self.assertEqual(
                expected_jobs[job_name]['runner_module_name'],
                job['runner'].__module__
            )
dataset/ETHPy150Open openstack/turbo-hipster/tests/disabled_worker_manager.py/TestWorkerServer.test_job_configuration/original