X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=ice_validator%2Ftests%2Ftest_non_server_name.py;h=7a5c11f385d9c3aa46f828e5ffbdbb6f0f1a6f92;hb=9c7ab065e6477c035ffc6addf384abcef2e9588a;hp=7264ad06b4c188ffd30f44c890297b9121b408bf;hpb=ad3ccca5d510a1b2d5e138f72404d42e1f34af44;p=vvp%2Fvalidation-scripts.git diff --git a/ice_validator/tests/test_non_server_name.py b/ice_validator/tests/test_non_server_name.py index 7264ad0..7a5c11f 100644 --- a/ice_validator/tests/test_non_server_name.py +++ b/ice_validator/tests/test_non_server_name.py @@ -42,7 +42,6 @@ resource property name """ import os import collections -import pytest from .structures import Heat from .structures import HeatProcessor @@ -74,12 +73,7 @@ def test_non_server_name(yaml_file): """ h = Heat(filepath=yaml_file) - if not h.resources: - pytest.skip("No resources in this template") - non_servers = get_non_servers(h) - if not non_servers: - pytest.skip("No non-server resources in this template") bad = [] for rid, resource in non_servers.items(): @@ -151,7 +145,9 @@ def test_non_server_name(yaml_file): def test_non_server_name_unique(heat_template): """Test name has unique value """ - list_nest = nested_files.get_list_of_nested_files(heat_template, os.path.dirname(heat_template)) + list_nest = nested_files.get_list_of_nested_files( + heat_template, os.path.dirname(heat_template) + ) list_nest.append(heat_template) non_servers = {} for yaml_file in list_nest: @@ -167,4 +163,4 @@ def test_non_server_name_unique(heat_template): assert not bad, "Names must be unique," " not shared across resource ids.%s%s" % ( delim, delim.join("%s: %s" % (name, list(value)) for name, value in bad.items()), - ) \ No newline at end of file + )