Testing
The tool to check the availability or syntax of domain, IP or URL.
::
██████╗ ██╗ ██╗███████╗██╗ ██╗███╗ ██╗ ██████╗███████╗██████╗ ██╗ ███████╗
██╔══██╗╚██╗ ██╔╝██╔════╝██║ ██║████╗ ██║██╔════╝██╔════╝██╔══██╗██║ ██╔════╝
██████╔╝ ╚████╔╝ █████╗ ██║ ██║██╔██╗ ██║██║ █████╗ ██████╔╝██║ █████╗
██╔═══╝ ╚██╔╝ ██╔══╝ ██║ ██║██║╚██╗██║██║ ██╔══╝ ██╔══██╗██║ ██╔══╝
██║ ██║ ██║ ╚██████╔╝██║ ╚████║╚██████╗███████╗██████╔╝███████╗███████╗
╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═══╝ ╚═════╝╚══════╝╚═════╝ ╚══════╝╚══════╝
Provides some testing related utilities
Author: Nissar Chababy, @funilrys, contactTATAfunilrysTODTODcom
Special thanks: https://pyfunceble.github.io/#/special-thanks
Contributors: https://pyfunceble.github.io/#/contributors
Project link: https://github.com/funilrys/PyFunceble
Project documentation: https://docs.pyfunceble.com
Project homepage: https://pyfunceble.github.io/
License: ::
Copyright 2017, 2018, 2019, 2020, 2022, 2023, 2024 Nissar Chababy
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
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
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.
get_continue_databaset_object(db_session=None)
Provides the continue object to work with.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
db_session
|
Optional[Session]
|
A database session to use. |
None
|
Raises:
Type | Description |
---|---|
ValueError
|
When the given database type is unkown. |
Source code in PyFunceble/cli/utils/testing.py
get_destination_from_origin(origin)
Given the origin, we provides the destination.
Source code in PyFunceble/cli/utils/testing.py
get_inactive_dataset_object(db_session=None)
Provides the inactive object to work with.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
db_session
|
Optional[Session]
|
A database session to use. |
None
|
Raises:
Type | Description |
---|---|
ValueError
|
When the given database type is unkown. |
Source code in PyFunceble/cli/utils/testing.py
get_subjects_from_line(line, checker_type, *, subject_type='domain', adblock_inputline2subject=None, wildcard2subject=None, rpz_policy2subject=None, rpz_inputline2subject=None, inputline2subject=None, subject2complements=None, url2netloc=None, cidr2subject=None)
Provides the list of subject to test.
Source code in PyFunceble/cli/utils/testing.py
181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 |
|
get_testing_mode()
Tries to provides the testing mode to apply to the CLI.