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

Make t/53lean_startup.t robust wrt stacktrace details #143

Merged
merged 1 commit into from
May 15, 2022

Conversation

Leont
Copy link
Contributor

@Leont Leont commented Feb 19, 2022

This test checks if none of DBIC is loading anything unexpected. It
contains logic to skip over indirect loaders such as base, parent and
Class::C3::Componentised. However, this erroneously skips over direct
dependencies of such classes. In particular, it assigns the MRO::Compat
dependency in Class::C3::Componentised to whatever class it thinks it
loads CCC. Before ad89278 this worked out fine, because it would be
assigned to main, which while meaningless isn't part of DBIx::Class so
ignored. After ad89278, it's assigned to the class that loads CCC, which
is DBIx::Class::Componentised, which is part of DBIC, and hence fails
the test.

This test will cause it to not skip on for any BEGIN blocks inside an
indirect loader, therefor the MRO::Compat dependency will correctly be
assigned to Class::C3::Componentised.

This test checks if none of DBIC is loading anything unexpected. It
contains logic to skip over indirect loaders such as base, parent and
Class::C3::Componentised. However, this erroneously skips over direct
dependencies of such classes. In particular, it assigns the MRO::Compat
dependency in Class::C3::Componentised to whatever class it thinks it
loads CCC. Before ad89278 this worked out fine, because it would be
assigned to main, which while meaningless isn't part of DBIx::Class so
ignored. After ad89278, it's assigned to the class that loads CCC, which
is DBIx::Class::Componentised, which is part of DBIC, and hence fails
the test.

This test will cause it to not skip on for any BEGIN blocks inside an
indirect loader, therefor the MRO::Compat dependency will correctly be
assigned to Class::C3::Componentised.
ribasushi added a commit that referenced this pull request May 15, 2022
@ribasushi ribasushi merged commit f1e3b00 into Perl5:maint/0.0828xx May 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants