Terarea  2
The automation project
Loading...
Searching...
No Matches
test_action_logger Namespace Reference

Functions

None _add_dummy_user ()
 
None _add_dummy_action ()
 
None _remove_dummy_user ()
 
None _remove_dummy_action ()
 
None _remove_log_line (Union[int, Dict[str, int]] log_id)
 
Dict[str, Any] _get_log_lines (str action_id="")
 
None test_log_event_info ()
 
None test_log_event_unknown ()
 
None test_log_event_success ()
 
None test_log_event_debug ()
 
None test_log_event_warning ()
 
None test_log_event_error ()
 
None test_log_event_critical ()
 
None test_log_event_fatal ()
 
None test_log_success ()
 
None test_log_debug ()
 
None test_log_warning ()
 
None test_log_error ()
 
None test_log_critical ()
 
None test_log_fatal ()
 
None test_log_unknown ()
 
None test_get_logs ()
 
None test_get_logs_unknown ()
 
None test_get_logs_info ()
 
None test_get_logs_success ()
 
None test_get_logs_debug ()
 
None test_get_logs_warning ()
 
None test_get_logs_error ()
 
None test_get_logs_critical ()
 
None test_get_logs_fatal ()
 

Variables

 ERROR = TCONST.ERROR
 
 SUCCESS = TCONST.SUCCESS
 
 DEBUG = TCONST.DEBUG
 
 RDI = RuntimeData(TCONST.SERVER_HOST, TCONST.PORT, "Area", ERROR, SUCCESS)
 
 BRI
 
 boilerplate_responses_initialised
 
 boilerplate_non_http_initialised
 
 runtime_data_initialised
 
 success
 
 error
 
 debug
 
 SQLI
 
 database_link
 
 ACLI
 
 PHI
 
dict TEST_INFO
 

Detailed Description

_summary_
    File in charge of testing the logger class for the actions

Function Documentation

◆ _add_dummy_action()

None test_action_logger._add_dummy_action ( )
protected
_summary_
    Function in charge of adding a dummy action to the database.

Definition at line 123 of file test_action_logger.py.

◆ _add_dummy_user()

None test_action_logger._add_dummy_user ( )
protected
_summary_
    Function in charge of adding a dummy user to the database.

Definition at line 79 of file test_action_logger.py.

◆ _get_log_lines()

Dict[str, Any] test_action_logger._get_log_lines ( str action_id = "")
protected
_summary_
    Function in charge of getting the log line from the database.

Definition at line 219 of file test_action_logger.py.

◆ _remove_dummy_action()

None test_action_logger._remove_dummy_action ( )
protected
_summary_
    Function in charge of removing the dummy action from the database.

Definition at line 189 of file test_action_logger.py.

◆ _remove_dummy_user()

None test_action_logger._remove_dummy_user ( )
protected
_summary_
    Function in charge of removing the dummy user from the database.

Definition at line 178 of file test_action_logger.py.

◆ _remove_log_line()

None test_action_logger._remove_log_line ( Union[int, Dict[str, int]] log_id)
protected
_summary_
    Function in charge of removing the log line from the database.

Args:
    log_id (int): _description_

Definition at line 199 of file test_action_logger.py.

◆ test_get_logs()

None test_action_logger.test_get_logs ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 798 of file test_action_logger.py.

◆ test_get_logs_critical()

None test_action_logger.test_get_logs_critical ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 1144 of file test_action_logger.py.

◆ test_get_logs_debug()

None test_action_logger.test_get_logs_debug ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 997 of file test_action_logger.py.

◆ test_get_logs_error()

None test_action_logger.test_get_logs_error ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 1095 of file test_action_logger.py.

◆ test_get_logs_fatal()

None test_action_logger.test_get_logs_fatal ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 1193 of file test_action_logger.py.

◆ test_get_logs_info()

None test_action_logger.test_get_logs_info ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 899 of file test_action_logger.py.

◆ test_get_logs_success()

None test_action_logger.test_get_logs_success ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 948 of file test_action_logger.py.

◆ test_get_logs_unknown()

None test_action_logger.test_get_logs_unknown ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 850 of file test_action_logger.py.

◆ test_get_logs_warning()

None test_action_logger.test_get_logs_warning ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 1046 of file test_action_logger.py.

◆ test_log_critical()

None test_action_logger.test_log_critical ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 687 of file test_action_logger.py.

◆ test_log_debug()

None test_action_logger.test_log_debug ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 576 of file test_action_logger.py.

◆ test_log_error()

None test_action_logger.test_log_error ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 650 of file test_action_logger.py.

◆ test_log_event_critical()

None test_action_logger.test_log_event_critical ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 463 of file test_action_logger.py.

◆ test_log_event_debug()

None test_action_logger.test_log_event_debug ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 349 of file test_action_logger.py.

◆ test_log_event_error()

None test_action_logger.test_log_event_error ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 425 of file test_action_logger.py.

◆ test_log_event_fatal()

None test_action_logger.test_log_event_fatal ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 501 of file test_action_logger.py.

◆ test_log_event_info()

None test_action_logger.test_log_event_info ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 235 of file test_action_logger.py.

◆ test_log_event_success()

None test_action_logger.test_log_event_success ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 311 of file test_action_logger.py.

◆ test_log_event_unknown()

None test_action_logger.test_log_event_unknown ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 273 of file test_action_logger.py.

◆ test_log_event_warning()

None test_action_logger.test_log_event_warning ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 387 of file test_action_logger.py.

◆ test_log_fatal()

None test_action_logger.test_log_fatal ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 724 of file test_action_logger.py.

◆ test_log_success()

None test_action_logger.test_log_success ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 539 of file test_action_logger.py.

◆ test_log_unknown()

None test_action_logger.test_log_unknown ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 761 of file test_action_logger.py.

◆ test_log_warning()

None test_action_logger.test_log_warning ( )
_summary_
    Function in charge of testing the log_event function.

Definition at line 613 of file test_action_logger.py.

Variable Documentation

◆ ACLI

test_action_logger.ACLI
Initial value:
1= ActionLogger(
2 runtime_data=RDI,
3 success=SUCCESS,
4 error=ERROR,
5 debug=DEBUG
6)

Definition at line 59 of file test_action_logger.py.

◆ boilerplate_non_http_initialised

test_action_logger.boilerplate_non_http_initialised

Definition at line 40 of file test_action_logger.py.

◆ boilerplate_responses_initialised

test_action_logger.boilerplate_responses_initialised

Definition at line 39 of file test_action_logger.py.

◆ BRI

test_action_logger.BRI
Initial value:
1= BoilerplateResponses(
2 runtime_data=RDI,
3 debug=DEBUG
4)

Definition at line 35 of file test_action_logger.py.

◆ database_link

test_action_logger.database_link

Definition at line 55 of file test_action_logger.py.

◆ DEBUG

test_action_logger.DEBUG = TCONST.DEBUG

Definition at line 31 of file test_action_logger.py.

◆ debug

test_action_logger.debug

Definition at line 44 of file test_action_logger.py.

◆ ERROR

test_action_logger.ERROR = TCONST.ERROR

Definition at line 29 of file test_action_logger.py.

◆ error

test_action_logger.error

Definition at line 43 of file test_action_logger.py.

◆ PHI

test_action_logger.PHI
Initial value:
1= PasswordHandling(
2 error=ERROR,
3 success=SUCCESS,
4 debug=DEBUG
5)

Definition at line 66 of file test_action_logger.py.

◆ RDI

test_action_logger.RDI = RuntimeData(TCONST.SERVER_HOST, TCONST.PORT, "Area", ERROR, SUCCESS)

Definition at line 34 of file test_action_logger.py.

◆ runtime_data_initialised

test_action_logger.runtime_data_initialised

Definition at line 41 of file test_action_logger.py.

◆ SQLI

test_action_logger.SQLI
Initial value:
1= SQL(
2 url=CONST.DB_HOST,
3 port=CONST.DB_PORT,
4 username=CONST.DB_USER,
5 password=CONST.DB_PASSWORD,
6 db_name=CONST.DB_DATABASE,
7 debug=DEBUG
8)

Definition at line 47 of file test_action_logger.py.

◆ SUCCESS

test_action_logger.SUCCESS = TCONST.SUCCESS

Definition at line 30 of file test_action_logger.py.

◆ success

test_action_logger.success

Definition at line 42 of file test_action_logger.py.

◆ TEST_INFO

dict test_action_logger.TEST_INFO
Initial value:
1= {
2 "user_id": 0,
3 "action_id": 0,
4 "cache_busting": TCONST.CACHE_BUSTER_ADMIN
5}

Definition at line 72 of file test_action_logger.py.