Uh oh!
There was an error while loading. Please reload this page.
Add DSC resource list to manifest - #5997
Conversation
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
| std::map<InstallerSwitchType, | ||
| Utility::NormalizedString>*, |
There was a problem hiding this comment.
| std::map<InstallerSwitchType, | |
| Utility::NormalizedString>*, | |
| std::map<InstallerSwitchType, Utility::NormalizedString>*, |
There was a problem hiding this comment.
I was a little overly aggressive with the reformat 🦖
| std::vector<DesiredStateConfigurationContainerInfo>*, | ||
| DesiredStateConfigurationContainerInfo*, | ||
| DesiredStateConfigurationResourceInfo* |
There was a problem hiding this comment.
Nit: All the others (except for the auth ones) seem to be sorted alphabetically
| if (fullValidation) | ||
| { | ||
| for (const auto& container : installer.DesiredStateConfiguration) | ||
| { | ||
| if (container.Type == DesiredStateConfigurationContainerType::PowerShell) | ||
| { | ||
| // PowerShell DSC is not supported in community repo. |
There was a problem hiding this comment.
Nit: It's surprising to me that fullValidation means "is supported in the community repo"
| "Type": { | ||
| "type": "string", | ||
| "description": "The name of the resource.", | ||
| "pattern": "^\\w+(\\.\\w+){0,2}\\/\\w+$", |
There was a problem hiding this comment.
Nit: I don't know if we can add comments to these schemas, but I'd appreciate an explanation of what the regex looks for, so that I don't need to parse it next time I read it.
| "pattern": "^[A-Za-z][-._A-Za-z0-9]*$", | ||
| "maxLength": 100 |
There was a problem hiding this comment.
Do you have a source for these being the only allowed module names?
| VerifyV1ManifestContent(mergedManifest, false, ManifestVer{ s_ManifestVersionV1_12 }); | ||
| } | ||
| TEST_CASE("ValidateV1_28GoodManifestAndVerifyContents", "[ManifestValidation]") |
There was a problem hiding this comment.
Is this the same test for every version? Should we make it a macro or something at some point?
There was a problem hiding this comment.
I made functions for this and the write test core methods. Then created a macro for the version specifics.
…o-ized copy-paste tests
This comment was marked as outdated.
This comment was marked as outdated.
| "type": "string", | ||
| "description": "The name of the module containing resources.", | ||
| "pattern": "^[A-Za-z][-._A-Za-z0-9]*$", | ||
| "$comment": "From nuget package id, although PowerShell convention is slightly more strict: https://learn.microsoft.com/en-us/nuget/reference/errors-and-warnings/nu1017", |
There was a problem hiding this comment.
nit: this is not at all important, but I like removing the locale en-us from doc links, so that anybody that opens it gets it in their language automatically.
Implements #3523
Change
Creates manifest version 1.28.0, adding the DSC resource list to the installer, similar to described in the issue. Is a little deeper and more extensible than the suggested version. As an example, winget's own full list would look like:
But
PowerShellwill be blocked from winget-pkgs due to the inherently independent nature of the modules and packages. With a future ownership model we could likely allow them to be listed.Validation
Standard unit tests added covering new manifest version features.
Microsoft Reviewers: Open in CodeFlow