~thomir-deactivatedaccount/testtools/add-nonfatal-assertions

« back to all changes in this revision

Viewing changes to testtools/matchers/_dict.py

  • Committer: Robert Collins
  • Author(s): Xiao Hanyu
  • Date: 2013-10-13 04:09:05 UTC
  • Revision ID: git-v1:d15b7574ee20a0d9bda2bb089d940570a317d4e1
Fix a KeysEqual bug.

See https://bugs.launchpad.net/testtools/+bug/1177217 for details.

Show diffs side-by-side

added added

removed removed

Lines of Context:
241
241
        """
242
242
        super(KeysEqual, self).__init__()
243
243
        try:
244
 
            self.expected = expected.keys()
 
244
            self.expected = expected[0].keys()
245
245
        except AttributeError:
246
246
            self.expected = list(expected)
247
247