ecap5_treq.check module
- class ecap5_treq.check.Check(testsuite: str, testcase: str, shortid: str, status: int = None, error_msg: str = None)
- Bases: - object- A Check is a test that can be traced to requirements - to_str() str
- Convert the check to a string - Returns:
- a string representing the check 
- Return type:
- str 
 
 
- ecap5_treq.check.import_checks(path) list[Check]
- Imports checks from test source files - Parameters:
- path (str) – path to the root of the test source files 
- Returns:
- a list of checks from the test source files 
- Return type:
- list[Check] 
 
- ecap5_treq.check.import_testdata(path: str) list[Check]
- Imports checks from the testdata files - Parameters:
- path (str) – path to the root of the testdata files 
- Returns:
- a list of checks from the testdata files where the status is completed 
- Return type:
- list[Check] 
 
- ecap5_treq.check.process_check_id(id: str) [<class 'str'>, <class 'str'>, <class 'str'>]
- Converts a raw check id to the appropriate fields - The format of the raw check id is : “testsuite.testcase.id” - Parameters:
- id (str) – raw check id 
- Returns:
- a tuple containing testsuite, testcase and id 
- Return type:
- tuple[str, str, str] 
 
- ecap5_treq.check.process_keyword(cur: int, content: str) int
- Increments cur to point to the char following the next parenthesis in content - Parameters:
- cur (int) – pointer to the starting char in content 
- content (str) – content string 
 
- Returns:
- the incremented cur pointing to the char following the next parenthesis in content 
- Return type:
- int 
 
- ecap5_treq.check.process_string(cur: int, content: str) tuple[int, str]
- Recovers a string contained between matching quotation marks starting from the char pointed by cur - An empty string is returned in case where the first char pointed by cur is not a quotation mark - Parameters:
- cur (int) – pointer to the starting char in content 
- content (str) – content string 
 
- Returns:
- a tuple containing both an incremented cur pointing to the next char after the quotation mark and the recovered string 
- Return type:
- tuple[int, str]