diff --git a/linspector/services/http/httpconnect.py b/linspector/services/http/httpconnect.py new file mode 100644 index 0000000..3e13181 --- /dev/null +++ b/linspector/services/http/httpconnect.py @@ -0,0 +1,24 @@ +""" +This file is part of Linspector (https://linspector.org/) +Copyright (c) 2022 Johannes Findeisen . All Rights Reserved. +See LICENSE.txt (MIT license). +""" +from linspector.core.service import Service + + +def create(configuration, environment, log): + return HTTPConnectService(configuration, environment, log) + + +# Get the status code returned by a http request. Action handling is configured using kwargs. So, +# let's say all below 4** are no errors and others are an error. Or maybe define ranges, or just +# maybe the status code that produces an error. +class HTTPConnectService(Service): + def __init__(self, configuration, environment, log): + super().__init__(configuration, environment, log) + self.__configuration = configuration + self.__environment = environment + self.__log = log + + def execute(self, **kwargs): + return diff --git a/linspector/services/http/httpkeyword.py b/linspector/services/http/httpkeyword.py index ac090ff..d4d328f 100644 --- a/linspector/services/http/httpkeyword.py +++ b/linspector/services/http/httpkeyword.py @@ -10,6 +10,7 @@ def create(configuration, environment, log): return HTTPKeywordService(configuration, environment, log) +# Get a true or false when a keyword is found in a http request. class HTTPKeywordService(Service): def __init__(self, configuration, environment, log): super().__init__(configuration, environment, log)