'```task_configure_flocker_agent`` writes a ``/etc/flocker/agent.yml``
file which contains the backend configuration passed to it.'

def test_agent_yml(self):

    control_address = BASIC_AGENT_YML['control-service']['hostname']
    expected_pool = u'some-test-pool'
    expected_backend_configuration = dict(pool=expected_pool)
    commands = task_configure_flocker_agent(control_node=control_address, dataset_backend=backend_loader.get(BASIC_AGENT_YML['dataset']['backend']), dataset_backend_configuration=expected_backend_configuration, logging_config=thaw(BASIC_AGENT_YML['logging']))
    [put_agent_yml] = list((effect.intent for effect in commands.intent.effects if isinstance(effect.intent, Put)))
    expected_agent_config = BASIC_AGENT_YML.set('dataset', BASIC_AGENT_YML['dataset'].update(expected_backend_configuration))
    self.assertEqual(put(content=yaml.safe_dump(thaw(expected_agent_config)), path=THE_AGENT_YML_PATH, log_content_filter=_remove_dataset_fields).intent, put_agent_yml)
