Fix creation of nuget symbol file
What does this MR do and why?
Fix creation of nuget symbol file
In !170692 (merged) we've
added the changes to Packages::Nuget::Symbol to work with
both Packages::Package and Packages::Nuget::Package that
caused the issue in Packages::Nuget::Symbols::CreateSymbolFilesService
that was only working correctly with the
Packages::Nuget::Package class.
References
Please include cross links to any resources that are relevant to this MR This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
No.
How to set up and validate locally
When the feature flag is disabled
-
Disable the feature flag:
Feature.disable(:nuget_extract_nuget_package_model) -
Make sure you have the NuGet CLI installed (see nuget docs for links to installation pages).
-
Add a project as your NuGet source in your local GitLab NuGet Repository:
nuget source Add -Name localhost -Source "http://gdk.test:3000/api/v4/projects/<project_id>/packages/nuget/index.json" -UserName <gitlab_username> -Password <personal_access_token>
- Push a NuGet package that has a symbol to your project. You can test using this one. Download both the
.nupkg&.snupkgfiles in the same directory, and then push the.nupkg. The.snupkgfile should be pushed automatically after the.nupkgis pushed.
nuget push Package.nupkg -Source localhost
- Once the package is published, in the rails console verify that the symbol records have been created:
Packages::Nuget::Symbol.last
When the feature flag is enabled
- Enable the feature flag:
Feature.disable(:nuget_extract_nuget_package_model)
Repeat the steps 2-5 from when the feature flag is disabled.