X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=auth%2Fauth-cass%2Fsrc%2Ftest%2Fjava%2Forg%2Fonap%2Faaf%2Fauth%2Fdao%2Fcached%2FJU_CachedCredDAOTest.java;h=3d98dcdadff02cfd6c0c98d5609a86a575a439e2;hb=6dd9704640eb8cc8d6b4ccd266e40a3f6f589e75;hp=06285357925e6c834e75c7f023d0f56304e0c707;hpb=556e22af6ff1c11d6e76eda97a8b26f5f14cec83;p=aaf%2Fauthz.git diff --git a/auth/auth-cass/src/test/java/org/onap/aaf/auth/dao/cached/JU_CachedCredDAOTest.java b/auth/auth-cass/src/test/java/org/onap/aaf/auth/dao/cached/JU_CachedCredDAOTest.java index 06285357..3d98dcda 100644 --- a/auth/auth-cass/src/test/java/org/onap/aaf/auth/dao/cached/JU_CachedCredDAOTest.java +++ b/auth/auth-cass/src/test/java/org/onap/aaf/auth/dao/cached/JU_CachedCredDAOTest.java @@ -7,9 +7,9 @@ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -39,32 +39,32 @@ import org.onap.aaf.auth.layer.Result; public class JU_CachedCredDAOTest { - @Mock - private CIDAO info; - @Mock - private CredDAO dao; - private AuthzTrans trans; - @Mock - private Result> value; + @Mock + private CIDAO info; + @Mock + private CredDAO dao; + private AuthzTrans trans; + @Mock + private Result> value; - @Before - public void setUp() throws Exception { - initMocks(this); + @Before + public void setUp() throws Exception { + initMocks(this); - when(dao.readID(trans, "id")).thenReturn(value); - } + when(dao.readID(trans, "id")).thenReturn(value); + } - @Test - public void testOk() { - when(value.isOK()).thenReturn(false); - CachedCredDAO ccDao = new CachedCredDAO(dao, info, 100l); + @Test + public void testOk() { + when(value.isOK()).thenReturn(false); + CachedCredDAO ccDao = new CachedCredDAO(dao, info, 100l); - ccDao.readNS(trans, "ns"); - Result> result = ccDao.readID(trans, "id"); + ccDao.readNS(trans, "ns"); + Result> result = ccDao.readID(trans, "id"); - assertEquals(result.status, Status.OK); - verify(dao).readNS(trans, "ns"); - verify(dao).readID(trans, "id"); - } + assertEquals(result.status, Status.OK); + verify(dao).readNS(trans, "ns"); + verify(dao).readID(trans, "id"); + } }