Skip to content

[Bug]: A few component unit tests fail to compile with 1.89.0 (MSRV) #1530

@makubacki

Description

@makubacki

Is there an existing issue for this?

  • I have searched existing issues

Current Behavior

Testing with the nightly-2026-06-23 toolchain (cargo +nightly-2026-06-23 test) results in the following:

---- component::params::tests::test_config_cannot_be_accessed_while_unlocked stdout ----

thread 'component::params::tests::test_config_cannot_be_accessed_while_unlocked' panicked at sdk\patina\src\component\params.rs:922:9:
assertion failed: Config::<i32>::try_validate(&id,
        (&storage).into()).is_err_and(|err|
        err == "patina::component::params::Config<'_, i32> not available.")    

---- component::params::tests::test_config_mut_cannot_be_accessed_while_locked stdout ----

thread 'component::params::tests::test_config_mut_cannot_be_accessed_while_locked' panicked at sdk\patina\src\component\params.rs:936:9:
assertion failed: ConfigMut::<i32>::try_validate(&id,
        (&storage).into()).is_err_and(|err|
        err == "patina::component::params::ConfigMut<'_, i32> not available.") 

---- component::struct_component::tests::test_component_run_handling_works_as_expected stdout ----

thread 'component::struct_component::tests::test_component_run_handling_works_as_expected' panicked at sdk\patina\src\component\struct_component.rs:204:9:    
assertion `left == right` failed
  left: Some("patina::component::params::ConfigMut<u32>")
 right: Some("patina::component::params::ConfigMut<'_, u32>")

The tests are written to assert against the string rendered in newer toolchains that includes the generic lifetime parameter.

Expected Behavior

Test pass with the MSRV to the currently supported toolchain.

Steps To Reproduce

  • rustup toolchain install nightly-2026-06-23
  • cargo +nightly-2026-06-23 test

Build Environment

N/A

Version Information

Tag (as of): 21.0.4

Urgency

Medium

Are you going to fix this?

I will fix it

Do you need maintainer feedback?

No maintainer feedback needed

Anything else?

No response

Metadata

Metadata

Assignees

Labels

type:bugSomething isn't workingurgency:mediumImportant with a moderate impact

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions