示例#1
0
    def perform_request(self):
        """ Perform actual request to service, overridden from base class"""

        if not self.layers:
            self.result.set(False, 'Found no TMS Layers')
            return

        self.result.start()

        results_failed_total = []
        for layer_name in self.layers.keys():
            # Layer name is last part of full URL
            self._parameters['layer'] = layer_name.split('1.0.0/')[-1]
            self._parameters['extension'] = self.layers[layer_name].extension

            # Let the templated parent perform
            Probe.perform_request(self)
            self.run_checks()

            # Only keep failed Layer results
            # otherwise with 100s of Layers the report grows out of hand...
            results_failed = self.result.results_failed
            if len(results_failed) > 0:
                # We have a failed layer: add to result message
                for result in results_failed:
                    result.message = 'layer %s: %s' % \
                                     (layer_name, result.message)

                results_failed_total += results_failed
                self.result.results_failed = []

            self.result.results = []

        self.result.results_failed = results_failed_total
        self.result.results = results_failed_total
示例#2
0
    def perform_request(self):
        """ Perform actual request to service, overridden from base class"""

        if not self.feature_types:
            self.result.set(False, 'Found no WFS Feature Types')
            return

        self.result.start()

        results_failed_total = []
        for feature_type in self.feature_types:
            self._parameters['type_name'] = feature_type

            # Let the templated parent perform
            Probe.perform_request(self)
            self.run_checks()

            # Only keep failed feature_type results
            # otherwise with 100s of FTs the report grows out of hand...
            results_failed = self.result.results_failed
            if len(results_failed) > 0:
                # We have a failed feature_type: add to result message
                for result in results_failed:
                    result.message = 'feature_type %s: %s' % \
                                     (feature_type, result.message)

                results_failed_total += results_failed
                self.result.results_failed = []

            self.result.results = []

        self.result.results_failed = results_failed_total
示例#3
0
    def perform_request(self):
        """ Perform actual request to service, overridden from base class"""

        if not self.feature_types:
            self.result.set(False, 'Found no WFS Feature Types')
            return

        self.result.start()

        results_failed_total = []
        for feature_type in self.feature_types:
            self._parameters['type_name'] = feature_type

            # Let the templated parent perform
            Probe.perform_request(self)
            self.run_checks()

            # Only keep failed feature_type results
            # otherwise with 100s of FTs the report grows out of hand...
            results_failed = self.result.results_failed
            if len(results_failed) > 0:
                # We have a failed feature_type: add to result message
                for result in results_failed:
                    result.message = 'feature_type %s: %s' % \
                                     (feature_type, result.message)

                results_failed_total += results_failed
                self.result.results_failed = []

            self.result.results = []

        self.result.results_failed = results_failed_total
示例#4
0
    def perform_request(self):
        """ Perform actual request to service, overridden from base class"""

        if not self.layers:
            self.result.set(False, 'Found no WMS Layers')
            return

        self.result.start()

        results_failed_total = []
        for layer in self.layers:
            self._parameters['layers'] = [layer]

            # Let the templated parent perform
            Probe.perform_request(self)
            self.run_checks()

            # Only keep failed Layer results
            # otherwise with 100s of Layers the report grows out of hand...
            results_failed = self.result.results_failed
            if len(results_failed) > 0:
                # We have a failed layer: add to result message
                for result in results_failed:
                    result.message = 'layer %s: %s' % (layer, result.message)

                results_failed_total += results_failed
                self.result.results_failed = []

            self.result.results = []

        self.result.results_failed = results_failed_total
示例#5
0
    def perform_request(self):
        """ Perform actual request to service, overridden from base class"""

        if not self.layers:
            self.result.set(False, 'Found no TMS Layers')
            return

        self.result.start()

        results_failed_total = []
        for layer_name in self.layers.keys():
            # Layer name is last part of full URL
            self._parameters['layer'] = layer_name.split('1.0.0/')[-1]
            self._parameters['extension'] = self.layers[layer_name].extension

            # Let the templated parent perform
            Probe.perform_request(self)
            self.run_checks()

            # Only keep failed Layer results
            # otherwise with 100s of Layers the report grows out of hand...
            results_failed = self.result.results_failed
            if len(results_failed) > 0:
                # We have a failed layer: add to result message
                for result in results_failed:
                    result.message = 'layer %s: %s' % \
                                     (layer_name, result.message)

                results_failed_total += results_failed
                self.result.results_failed = []

            self.result.results = []

        self.result.results_failed = results_failed_total
        self.result.results = results_failed_total