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 targeting pack test fail if nupkg doesn't exist but should've been built #3836

Open
dagood opened this issue Nov 11, 2019 · 4 comments
Open
Assignees
Labels
area-Setup test-enhancement Improvements of test source code
Milestone

Comments

@dagood
Copy link
Member

dagood commented Nov 11, 2019

When adding functionality to skip building targeting packs in servicing builds unless they're being patched (https://github.com/dotnet/core-setup/issues/8735), the tests broke because they assumed the targeting packs would always be built.

The short-term fix was to change the tests to simply pass when the nupkg doesn't exist.

master: dotnet/core-setup#8824
windowsdesktop master: dotnet/windowsdesktop#230
3.0: dotnet/core-setup#8827
3.1: dotnet/core-setup#8828

This could cause the tests to pass even when a nupkg should have been created. It's unlikely this will cause problems (details in 3.0/3.1 PRs above) but in any case, it's a regression in testing coverage that should be closed.

The difficulty here is wiring through the info about whether a package should have been created all the way to the test code. A simple approach would be to put a {nupkgFileName}.intentionallyNotBuilt file in the artifacts dir when a build is skipped, then the tests look for it based on convention.

@msftgits msftgits transferred this issue from dotnet/core-setup Jan 30, 2020
@msftgits msftgits added this to the 5.0 milestone Jan 30, 2020
@dagood dagood removed the Triaged label Jan 30, 2020
@NikolaMilosavljevic NikolaMilosavljevic modified the milestones: 5.0.0, 6.0.0 Jun 25, 2020
@NikolaMilosavljevic
Copy link
Member

[Triage] @jkoritzinsky is this implemented with SharedFX refactoring or would it be valuable to add it?

@jkoritzinsky
Copy link
Member

I think including some sort of check tooling for this might be useful, but it isn't urgent. This was not implemented with the SharedFX refactoring.

@MichaelSimons MichaelSimons modified the milestones: 6.0.0, 7.0.0 Aug 12, 2021
@NikolaMilosavljevic
Copy link
Member

@ericstj does this test make sense now that we are servicing targeting packs with every release?

@ericstj
Copy link
Member

ericstj commented Aug 3, 2022

Maybe those tests could be reverted back to the not do this:

The short-term fix was to change the tests to simply pass when the nupkg doesn't exist.

@NikolaMilosavljevic NikolaMilosavljevic self-assigned this Aug 5, 2022
@NikolaMilosavljevic NikolaMilosavljevic modified the milestones: 7.0.0, 8.0.0 Aug 15, 2022
@NikolaMilosavljevic NikolaMilosavljevic modified the milestones: 8.0.0, Future Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-Setup test-enhancement Improvements of test source code
Projects
None yet
Development

No branches or pull requests

6 participants