X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2FTransactionContextWrapperTest.java;h=af6e782ed7a45063f3f5b955f755d9227a29f6d7;hb=70b924258e6c87219c38bcfefb3781ee3d2e2d02;hp=bc98f9ac3f3b096ff228879837fdf3fb7cf9b60c;hpb=4379f102fa0c85abf58f60d81fec9c698582fb1a;p=controller.git diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/TransactionContextWrapperTest.java b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/TransactionContextWrapperTest.java index bc98f9ac3f..af6e782ed7 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/TransactionContextWrapperTest.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/TransactionContextWrapperTest.java @@ -1,3 +1,11 @@ +/* + * Copyright (c) 2014, 2015 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ + package org.opendaylight.controller.cluster.datastore; import static org.junit.Assert.assertEquals; @@ -7,27 +15,23 @@ import org.junit.Before; import org.junit.Test; import org.mockito.Mock; import org.mockito.MockitoAnnotations; -import org.opendaylight.controller.cluster.datastore.identifiers.TransactionIdentifier; import org.opendaylight.controller.cluster.datastore.utils.ActorContext; public class TransactionContextWrapperTest { - - @Mock - TransactionIdentifier identifier; - @Mock - ActorContext actorContext; + private ActorContext actorContext; @Mock - TransactionContext transactionContext; + private TransactionContext transactionContext; - TransactionContextWrapper transactionContextWrapper; + private TransactionContextWrapper transactionContextWrapper; @Before public void setUp(){ MockitoAnnotations.initMocks(this); doReturn(DatastoreContext.newBuilder().build()).when(actorContext).getDatastoreContext(); - transactionContextWrapper = new TransactionContextWrapper(identifier, actorContext); + transactionContextWrapper = new TransactionContextWrapper(MockIdentifiers.transactionIdentifier( + TransactionContextWrapperTest.class, "mock"), actorContext); } @Test