X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=resources%2Ftools%2Fpresentation%2Fspecification_parser.py;h=97662899e3b5113068872ce739fb4cd7b083ec7f;hb=db902772e34d62893c60ebf7450ab84ca236eee3;hp=f994a59b35ae3d721be38a1e26ca1d724295b862;hpb=4ac3464851ff9dd688ab25d0324573284b6bf274;p=csit.git diff --git a/resources/tools/presentation/specification_parser.py b/resources/tools/presentation/specification_parser.py index f994a59b35..97662899e3 100644 --- a/resources/tools/presentation/specification_parser.py +++ b/resources/tools/presentation/specification_parser.py @@ -1,4 +1,4 @@ -# Copyright (c) 2018 Cisco and/or its affiliates. +# Copyright (c) 2019 Cisco and/or its affiliates. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at: @@ -112,6 +112,15 @@ class Specification(object): """ return self._specification["configuration"]["ignore"] + @property + def alerting(self): + """Getter - Alerting. + + :returns: Specification of alerts. + :rtype: dict + """ + return self._specification["configuration"]["alerting"] + @property def input(self): """Getter - specification - inputs. @@ -383,6 +392,12 @@ class Specification(object): except KeyError: self._specification["environment"]["build-dirs"] = None + try: + self._specification["environment"]["testbeds"] = \ + self._cfg_yaml[idx]["testbeds"] + except KeyError: + self._specification["environment"]["testbeds"] = None + logging.info("Done.") def _parse_configuration(self):