Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow override of the init function on a per-test basis #33

Open
t-moe opened this issue Jun 3, 2024 · 0 comments
Open

allow override of the init function on a per-test basis #33

t-moe opened this issue Jun 3, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@t-moe
Copy link
Contributor

t-moe commented Jun 3, 2024

Something like #[test(init=custom_init_123)]

@SergioGasquez wrote:

By the way, we are currently using this Context approach and the init function just calls the Context::init (https://github.com/esp-rs/esp-hal/blob/main/hil-test/tests/uart.rs#L61-L64)
Is there a way to have init method per test cases, eg: test_1 uses init_1 and test_2 uses init_2?
.... my idea would be to have 2 init functions. And there would be more than two tests, some would use one init fuction, some would use the other

@t-moe t-moe added the enhancement New feature or request label Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant