Exemple #1
0
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import os
import pytest

from ecosystem_tests.dorkl import (blueprints_upload, basic_blueprint_test,
                                   cleanup_on_failure, prepare_test)

from __init__ import (blueprint_id_filter, get_dirname_and_infra_name,
                      blueprint_list, get_cloudify_version, VersionsException,
                      PLUGINS_TO_UPLOAD, SECRETS_TO_CREATE)

prepare_test(plugins=PLUGINS_TO_UPLOAD,
             secrets=SECRETS_TO_CREATE,
             plugin_test=False,
             yum_packages=['libselinux-python3'])

virtual_machine_list = [
    b for b in blueprint_list if 'virtual-machine' in b
    and os.environ.get('IAAS', '') == os.path.basename(b).split('.yaml')[0]
]
getting_started_list = [b for b in blueprint_list if 'getting-started' in b]
openshift_list = ['kubernetes/plugin-examples/openshift/blueprint.yaml']


@pytest.fixture(scope='function', params=blueprint_list)
def upload_blueprints_for_validation(request):
    category = os.environ.get('VALIDATION_TEST_CATEGORY', '')
    if category in request.param:
        blueprints_upload(request.param, blueprint_id_filter(request.param))
Exemple #2
0
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import os
import pytest

from ecosystem_tests.dorkl import (blueprints_upload, basic_blueprint_test,
                                   cleanup_on_failure, prepare_test)

from __init__ import (blueprint_id_filter, get_dirname_and_infra_name,
                      blueprint_list, get_cloudify_version, VersionsException,
                      PLUGINS_TO_UPLOAD, SECRETS_TO_CREATE)

prepare_test(plugins=PLUGINS_TO_UPLOAD,
             secrets=SECRETS_TO_CREATE,
             plugin_test=False,
             pip_packages=['boto', 'boto3', 'selinux'])

virtual_machine_list = [
    b for b in blueprint_list if 'virtual-machine' in b
    and os.environ.get('IAAS', '') == os.path.basename(b).split('.yaml')[0]
]
getting_started_list = [b for b in blueprint_list if 'getting-started' in b]
openshift_list = ['kubernetes/plugin-examples/openshift/blueprint.yaml']


@pytest.fixture(scope='function', params=blueprint_list)
def upload_blueprints_for_validation(request):
    category = os.environ.get('VALIDATION_TEST_CATEGORY', '')
    if category in request.param:
        blueprints_upload(request.param, blueprint_id_filter(request.param))
Exemple #3
0
    basic_blueprint_test,
    cleanup_on_failure, prepare_test
)

SECRETS_TO_CREATE = {
    'openstack_username': False,
    'openstack_password': False,
    'openstack_tenant_name': False,
    'openstack_project_name': False,
    'openstack_auth_url': False,
    'openstack_region': False,
    'base_image_id': False,
    'base_flavor_id': False,
}

prepare_test(secrets=SECRETS_TO_CREATE)

blueprint_list = ['examples/blueprint-examples/virtual-machine/openstack.yaml']


@pytest.fixture(scope='function', params=blueprint_list)
def blueprint_examples(request):
    test_name = os.path.dirname(request.param).split('/')[-1:][0]
    inputs = 'external_network_id=ext-net'
    try:
        basic_blueprint_test(
            request.param,
            test_name,
            inputs=inputs,
        )
    except:
Exemple #4
0
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.


import os
import json
import pytest

from ecosystem_tests.dorkl import (
    basic_blueprint_test,
    cleanup_on_failure, prepare_test
)

prepare_test(secrets={})

blueprint_list = [
    'examples/blueprint-examples/utilities-examples/cloudify_cloudinit/simple.yaml',
    'examples/blueprint-examples/utilities-examples/cloudify_ssh_key/create-secret-agent-key.yaml',
    'examples/blueprint-examples/utilities-examples/cloudify_secrets/write-secret-blueprint.yaml',
    'examples/blueprint-examples/utilities-examples/cloudify_rest/example-github-status.yaml'
]


@pytest.fixture(scope='function', params=blueprint_list)
def blueprint_examples(request):
    test_name = os.path.dirname(request.param).split('/')[-1:][0]
    try:
        basic_blueprint_test(
            request.param,