Skip to content

Python function not callable from tavern script for saving  #946

@ShreyanshAyanger-Nykaa

Description

@ShreyanshAyanger-Nykaa

Hi, I am calling a save function after getting response from my api, now in the response received i need to format string and save only few elements present,

       response:
            status_code: 200
            save:
                headers:
                    res_key:
                        $ext:
                            function: testing_utils:extract_sessid
                            extra_kwargs:
                                head: headers

however, my tavern yaml is unable to call extract_string method in testing_utils file,
But other functions written in testing_utils are working fine with following syntax

           verify_response_with:
               -   function: testing_utils:check_jsonpath_value

Please help, basically in above way mentioned, the testing_utils file is not accessible ( inside save function) but in same tavern script existing test cases are able to access the same ( with verify_response_with).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions