

def test_create(self):
    self.mox.StubOutWithMock(db, 'aggregate_create')
    db.aggregate_create(self.context, {
        'name': 'foo',
        'uuid': uuidsentinel.fake_agg,
    }, metadata={
        'one': 'two',
    }).AndReturn(fake_aggregate)
    self.mox.ReplayAll()
    agg = aggregate.Aggregate(context=self.context)
    agg.name = 'foo'
    agg.metadata = {
        'one': 'two',
    }
    agg.uuid = uuidsentinel.fake_agg
    agg.create()
    agg.compare_obj(agg, fake_aggregate, subs=SUBS)

dataset/ETHPy150Open BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/tests/unit/objects/test_aggregate.py _TestAggregateObject.test_create/VarMisuse@116/150 `self`->`agg`