from pathlib import PurePath
from tests.integration_tests.validation.conformance_suite_config import ConformanceSuiteConfig

TIMING = {f'esef_conformance_suite_2021/esef_conformance_suite_2021/tests/inline_xbrl/{k}': v for k, v in {
    'G2-1-2/index.xml': 8.724,
    'G2-1-3_1/index.xml': 4.393,
    'G2-1-3_2/index.xml': 4.452,
    'G2-2-1/index.xml': 4.358,
    'G2-2-2/index.xml': 4.567,
    'G2-2-3/index.xml': 11.065,
    'G2-3-1_1/index.xml': 8.674,
    'G2-3-1_2/index.xml': 4.588,
    'G2-3-1_3/index.xml': 11.361,
    'G2-4-1_1/index.xml': 9.050,
    'G2-4-1_2/index.xml': 4.471,
    'G2-4-1_3/index.xml': 4.736,
    'G2-4-2_1/index.xml': 4.304,
    'G2-4-2_2/index.xml': 4.405,
    'G2-5-1_1/index.xml': 8.771,
    'G2-5-1_2/index.xml': 8.736,
    'G2-5-1_3/index.xml': 6.685,
    'G2-5-2/index.xml': 8.961,
    'G2-5-3/index.xml': 4.413,
    'G2-5-4_1/index.xml': 4.287,
    'G2-5-4_2/index.xml': 4.457,
    'G2-5-4_3/index.xml': 4.415,
    'G2-6-1_1/index.xml': 6.262,
    'G2-6-1_2/index.xml': 6.405,
    'G2-6-2/index.xml': 4.485,
    'G2-7-1_1/index.xml': 4.094,
    'G2-7-1_2/index.xml': 4.231,
    'G3-1-1_1/index.xml': 14.967,
    'G3-1-1_2/index.xml': 9.589,
    'G3-1-2/index.xml': 13.141,
    'G3-1-5/index.xml': 16.767,
    'G3-2-1/index.xml': 4.158,
    'G3-2-2/index.xml': 4.156,
    'G3-2-3/index.xml': 4.181,
    'G3-2-5/index.xml': 4.155,
    'G3-4-2_1/index.xml': 4.137,
    'G3-4-2_2/index.xml': 4.163,
    'G3-4-2_3/index.xml': 4.138,
    'G3-4-2_4/index.xml': 6.291,
    'G3-4-3_1/index.xml': 6.240,
    'G3-4-3_2/index.xml': 6.304,
    'G3-4-4/index.xml': 4.362,
    'G3-4-5_1/index.xml': 4.318,
    'G3-4-5_2/index.xml': 4.320,
    'G3-4-7/index.xml': 4.248,
    'G3-5-1/index.xml': 4.179,
    'RTS_Annex_III_Par_1/index.xml': 6.262,
    'RTS_Annex_III_Par_3_G3-1-3/index.xml': 2.108,
    'RTS_Annex_II_Par_1/index.xml': 6.297,
    'RTS_Annex_II_Par_1_RTS_Annex_IV_par_7/index.xml': 4.193,
    'RTS_Annex_II_Par_2/index.xml': 4.268,
    'RTS_Annex_IV_Par_11_G3-2-2/index.xml': 6.295,
    'RTS_Annex_IV_Par_12_G2-2-4/index.xml': 8.431,
    'RTS_Annex_IV_Par_14_G2-5-1/index.xml': 4.183,
    'RTS_Annex_IV_Par_1_G2-1-4/index.xml': 4.157,
    'RTS_Annex_IV_Par_2_G2-1-1/index.xml': 6.318,
    'RTS_Annex_IV_Par_4_1/index.xml': 4.206,
    'RTS_Annex_IV_Par_4_2/index.xml': 4.202,
    'RTS_Annex_IV_Par_4_G1-1-1_G3-4-5/index.xml': 11.126,
    'RTS_Annex_IV_Par_5_G3-4-6/index.xml': 10.570,
    'RTS_Annex_IV_Par_6/index.xml': 4.184,
    'RTS_Annex_IV_Par_8/index.xml': 6.279,
    'RTS_Annex_IV_Par_9_Par_10_G1-4-1_G1-4-2_G3-3-1_G3-3-2/index.xml': 16.773,
    'RTS_Art_3/index.xml': 8.407,
    'RTS_Art_6_a/index.xml': 4.066,
}.items()}

config = ConformanceSuiteConfig(
    approximate_relative_timing=TIMING,
    args=[
        '--disclosureSystem', 'esef-2021',
        '--formula', 'run',
    ],
    file='esef_conformance_suite_2021/esef_conformance_suite_2021/index_inline_xbrl.xml',
    info_url='https://www.esma.europa.eu/document/conformance-suite-2021',
    local_filepath='esef_conformance_suite_2021.zip',
    name=PurePath(__file__).stem,
    plugins=frozenset({'validate/ESEF'}),
    public_download_url='https://www.esma.europa.eu/sites/default/files/library/esef_conformance_suite_2021.zip',
    shards=8,
)
