'The ``invariant`` parameter is passed through to ``field``.'

@given(PYRSISTENT_STRUCT)
def test_invariant(self, klass):

    class Record(klass, ):
        value = pmap_field(int, int, invariant=(lambda pmap: ((len(pmap) == 1), 'Exactly    one    item    required.')))
    self.assertRaises(InvariantException, Record, value={})
    self.assertRaises(InvariantException, Record, value={1: 2, 3: 4})
    assert (Record(value={1: 2}).value == {1: 2})
