'This method ensures that the keys of the ``data`` match up to the keys
of ``expected``.
It covers the (extremely) common case where you want to make sure the
keys of a response match up to what is expected. This is typically less
fragile than testing the full structure, which can be prone to data
changes.'

def assertKeys(self, data, expected):

    self.assertEqual(sorted(data.keys()), sorted(expected))
