<commit_before>*** Settings ***
Suite Setup     My Setup
Force Tags      regression  jybot  pybot
Resource        atest_resource.txt

*** Test Cases ***
Suite Name
    [Documentation]  Checks that suite name can be set in metadata and the name is capitalized
    Should Be Equal  ${suite.name}  Metadata

Suite Document
    [Documentation]  Checks that suite document can be set in metadata. Also checks that backslashes are escaped correctly.
    Should Be Equal  ${suite.doc}  Test cases for metadata in Setting table (incl. imports) and within Test Case and Keyword tables. Text from multiple columns and lines is catenated with spaces. Real newlines need to be added with 'backslash+n' (e.g. '\n'). Also variables work since Robot 1.2, and they work from commandline too: Hello. Starting from RF 2.1 \${nonexisting} variables are just left unchanged. Of course escaping (e.g. '\${non-existing-in-suite-doc}' and '\\') works too.

Suite Test Setup
    ${test} =  Check Test Case  Test Case Documentation
    Verify Setup  ${test}  BuiltIn.Log  Default test setup

Suite Test Teardown
    ${test} =  Check Test Case  Test Case Documentation
    Verify Teardown  ${test}  BuiltIn.Log  Default test teardown

Suite Suite Setup
    Verify Setup  ${suite}  BuiltIn.Log  Default suite setup

Suite Suite Teardown
    Verify Teardown  ${suite}  BuiltIn.Log  Default suite teardown

Suite Test Timeout
    Check Test Case  Suite Level Test Timeout

User Metadata
    Equal  ${suite.metadata['Name']}  Value

User Metadata In Multiple Columns
    Equal  ${suite.metadata['Multiple Columns']}  Value in multiple columns

User Metadata In Multiple Lines
    Equal  ${suite.metadata['Multiple Lines']}  Value in multiple lines '\n\n' and with real newlines

User Metadata With Variables
    Equal  ${suite.metadata['Variables']}  Version: 1.2

User Metadata With Variable From Resource
    Equal  ${suite.metadata['Variable From Resource']}  Variable from a resource file

User Metadata With Variable From Commandline
    Equal  ${suite.metadata['Var From CLI']}  my_metadata

Unescaping Metadata In Setting Table
    [Documentation]  Test that metadata in setting table is unescaped correctly. This is already partly tested in Suite Documentation
    ${stderr} =  Get File  ${STDERR FILE}
    Fail If Contains  ${stderr}  \${non-existing-in-suite-doc}
    Equal  ${suite.metadata['Escaping']}  Three backslashes \\\\\\

Test Case Name
    [Documentation]  Check that test case name is capitalized
    ${test} =  Check testcase  lower case test case name
    Equals  ${test.name}  Lower Case Test Case Name

Test Case Documentation
    Check Test Doc  Test Case Documentation  Documentation for this test case

Test Case Documentation In Multiple Columns
    Check Test Doc  Test Case Documentation in Multiple Columns  Documentation for this  test case in multiple columns

Test Case Documentation In Multiple Lines
    Check Test Doc  Test Case Documentation in Multiple Lines  Documentation for this  test case in multiple lines

Test Case Documentation With Variables
    Check Test Doc  Test Case Documentation With Variables  Variables work in documentation  since Robot 1.2<commit_msg>Split tests for suite settings in their own suite<commit_after>*** Settings ***
Suite Setup     My Setup
Force Tags      regression  jybot  pybot
Resource        atest_resource.txt

*** Test Cases ***
Test Case Name
    [Documentation]  Check that test case name is capitalized
    ${test} =  Check testcase  lower case test case name
    Equals  ${test.name}  Lower Case Test Case Name

Test Case Documentation
    Check Test Doc  Test Case Documentation  Documentation for this test case

Test Case Documentation In Multiple Columns
    Check Test Doc  Test Case Documentation in Multiple Columns  Documentation for this  test case in multiple columns

Test Case Documentation In Multiple Lines
    Check Test Doc  Test Case Documentation in Multiple Lines  Documentation for this  test case in multiple lines

Test Case Documentation With Variables
    Check Test Doc  Test Case Documentation With Variables  Variables work in documentation  since Robot 1.2
{'fraction_non_alphanumeric': 0.05454984310885831, 'fraction_numerical': 0.0024137098720733766, 'mean_word_length': 3.736, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5654415', 'n_tokens_mistral': 1114, 'n_tokens_neox': 1063, 'n_words': 530}