From 4982577ac5c50ab7446145998f6c321d9d7f3d75 Mon Sep 17 00:00:00 2001 From: Dilip kumar Pampana Date: Sun, 15 Jul 2018 22:05:28 -0400 Subject: Junit for appc-config/Data-services Junit Test to GetConfigFileReferenceByVnfType in appc-config/Data-services Issue-ID: APPC-1080 Change-Id: I351cd7acc1ef6310d230d22bd7a0035d35722290 Signed-off-by: Dilip kumar Pampana --- .../onap/appc/data/services/db/TestDGGeneralDBService.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'appc-config/appc-data-services') diff --git a/appc-config/appc-data-services/provider/src/test/java/org/onap/appc/data/services/db/TestDGGeneralDBService.java b/appc-config/appc-data-services/provider/src/test/java/org/onap/appc/data/services/db/TestDGGeneralDBService.java index ba8b8aeb9..875c68bd7 100644 --- a/appc-config/appc-data-services/provider/src/test/java/org/onap/appc/data/services/db/TestDGGeneralDBService.java +++ b/appc-config/appc-data-services/provider/src/test/java/org/onap/appc/data/services/db/TestDGGeneralDBService.java @@ -5,6 +5,8 @@ * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved. * ================================================================================ * Copyright (C) 2017 Amdocs + * ================================================================================ + * Copyright (C) 2018 IBM * ============================================================================= * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -222,4 +224,15 @@ public class TestDGGeneralDBService { String fileCategory="testCategory"; dbService.getTemplateByVnfTypeNActionWithTemplateModelId(ctx, prefix, fileCategory, templateModelId); } + + @Test + public void testGetConfigFileReferenceByVnfType() throws Exception { + SvcLogicContext ctx = new SvcLogicContext(); + ctx.setAttribute("vnf-type", "test"); + ctx.setAttribute("request-action", "Configure"); + MockDGGeneralDBService dbService = MockDGGeneralDBService.initialise(); + QueryStatus status = dbService.getConfigFileReferenceByVnfType(ctx, "test"); + assertEquals(status, QueryStatus.SUCCESS); + + } } -- cgit 1.2.3-korg