'``Configuration.applications`` returns a ``dict``
of ``Application`` instances, one for each application key in the
supplied configuration.'

def test_dict_of_applications(self):

    config = dict(version=1, applications={u'mysql-hybridcluster': dict(image=u'flocker/mysql:v1.0.0', volume={u'mountpoint': u'/var/mysql/data'}), u'site-hybridcluster': {u'image': u'flocker/wordpress:v1.0.0', u'ports': [dict(internal=80, external=8080)], u'environment': {u'MYSQL_PORT_3306_TCP': u'tcp://172.16.255.250:3306', u'WP_ADMIN_USERNAME': u'administrator'}}})
    parser = FlockerConfiguration(config)
    applications = parser.applications()
    expected_applications = {u'mysql-hybridcluster': Application(name=u'mysql-hybridcluster', image=DockerImage(repository=u'flocker/mysql', tag=u'v1.0.0'), ports=frozenset(), links=frozenset(), volume=AttachedVolume(manifestation=Manifestation(dataset=Dataset(dataset_id=dataset_id_from_name(u'mysql-hybridcluster'), metadata=pmap({u'name': u'mysql-hybridcluster'})), primary=True), mountpoint=FilePath('/var/mysql/data'))), u'site-hybridcluster': Application(name=u'site-hybridcluster', image=DockerImage(repository=u'flocker/wordpress', tag=u'v1.0.0'), ports=frozenset([Port(internal_port=80, external_port=8080)]), links=frozenset(), environment=frozenset({u'MYSQL_PORT_3306_TCP': u'tcp://172.16.255.250:3306', u'WP_ADMIN_USERNAME': u'administrator'}.items()))}
    self.assertEqual(expected_applications, applications)
