def test_create_camp_assembly(self):
        if base.config_set_as('camp_enabled', False):
            self.skipTest('CAMP not enabled.')

        # create a plan using the CAMP API
        resp = self._create_camp_plan(data=test_plans.sample_data)
        self.assertEqual(resp.status, 201)
        uri = (resp.data['uri']
               [len(self.client.base_url):])

        ref_obj = json.dumps({'plan_uri': uri})

        resp, body = self.client.post(
            'camp/v1_1/assemblies',
            ref_obj,
            headers={'content-type': 'application/json'})
        self.assertEqual(resp.status, 201)

        assem_resp = base.SolumResponse(resp=resp,
                                        body=body,
                                        body_type='json')
        uuid = assem_resp.uuid
        if uuid is not None:
            # share the Solum client's list of created assemblies
            self.client.created_assemblies.append(uuid)
Test creating a CAMP assembly from a local plan resource.
dataset/ETHPy150Open openstack/solum/functionaltests/api/camp/v1_1/test_assemblies.py/TestAssembliesController.test_create_camp_assembly