Skip to content

Env as_contract function uses dummy variable #1673

Description

@mootz12

The as_contract function on the env adds an empty string as the "func" arg to with_test_contract_frame.

Is this needed? If not, the env should remove the "func" arg. If it is, we should add the func argument to as_contract.

It appears the "func" arg impacts the result of require_auth, so it might be useful for people to have when testing custom auth. For an example, see: https://github.com/stellar/rs-soroban-sdk/blob/main/tests/account/src/lib.rs

This was brought up in discussion on this PR: stellar/rs-soroban-env#1628

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