Skip to content

Commit

Permalink
Fix tests that fail on Python < 2.7.8.
Browse files Browse the repository at this point in the history
  • Loading branch information
itamarst committed Mar 2, 2015
1 parent 4fad8f0 commit a7dd251
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
4 changes: 2 additions & 2 deletions flocker/control/test/test_model.py
Expand Up @@ -6,7 +6,7 @@

from uuid import uuid4

from pyrsistent import InvariantException
from pyrsistent import InvariantException, pset

from twisted.trial.unittest import SynchronousTestCase
from twisted.python.filepath import FilePath
Expand Down Expand Up @@ -125,7 +125,7 @@ def test_repr(self):

class NodeInitTests(make_with_init_tests(
record_type=Node,
kwargs=dict(hostname=u'example.com', applications=frozenset([
kwargs=dict(hostname=u'example.com', applications=pset([
Application(name=u'mysql-clusterhq', image=object()),
Application(name=u'site-clusterhq.com', image=object()),
]))
Expand Down
17 changes: 9 additions & 8 deletions flocker/node/test/test_deploy.py
Expand Up @@ -9,7 +9,7 @@
from zope.interface.verify import verifyObject
from zope.interface import implementer

from pyrsistent import pmap
from pyrsistent import pmap, pset

from twisted.internet.defer import fail, FirstError, succeed, Deferred
from twisted.trial.unittest import SynchronousTestCase, TestCase
Expand Down Expand Up @@ -1192,13 +1192,14 @@ def test_discover_datasets(self):
d = api.discover_local_state()

self.assertEqual(
{Manifestation(
dataset=Dataset(
dataset_id=DATASET_ID,
metadata=pmap({u"name": u"site-example.com"})),
primary=True),
Manifestation(dataset=Dataset(dataset_id=DATASET_ID2),
primary=True)},
pset(
{Manifestation(
dataset=Dataset(
dataset_id=DATASET_ID,
metadata=pmap({u"name": u"site-example.com"})),
primary=True),
Manifestation(dataset=Dataset(dataset_id=DATASET_ID2),
primary=True)}),
self.successResultOf(d).manifestations)


Expand Down

0 comments on commit a7dd251

Please sign in to comment.