Rest & Java API layer - Query Datanodes using cpsPath that contains contains a leaf...
[cps.git] / cps-rest / src / test / groovy / org / onap / cps / rest / controller / AdminRestControllerSpec.groovy
index e0db106..ca99743 100755 (executable)
@@ -2,6 +2,7 @@
  *  ============LICENSE_START=======================================================
  *  Copyright (C) 2020 Pantheon.tech
  *  Modifications Copyright (C) 2020 Bell Canada. All rights reserved.
+ *  Copyright (C) 2021 Nordix Foundation
  *  ================================================================================
  *  Licensed under the Apache License, Version 2.0 (the "License");
  *  you may not use this file except in compliance with the License.
@@ -27,6 +28,7 @@ import static org.springframework.test.web.servlet.request.MockMvcRequestBuilder
 import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post
 
 import org.modelmapper.ModelMapper
+import org.onap.cps.api.CpsQueryService
 import org.onap.cps.api.CpsAdminService
 import org.onap.cps.api.CpsDataService
 import org.onap.cps.api.CpsModuleService
@@ -59,13 +61,16 @@ class AdminRestControllerSpec extends Specification {
     @SpringBean
     CpsDataService mockCpsDataService = Mock()
 
+    @SpringBean
+    CpsQueryService mockCpsQueryService = Mock()
+
     @SpringBean
     ModelMapper modelMapper = Mock()
 
     @Autowired
     MockMvc mvc
 
-    @Value('${rest.api.base-path}')
+    @Value('${rest.api.cps-base-path}')
     def basePath
 
     def dataspaceName = 'my_dataspace'