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

Add DotNet and NuGet package managers including tests #1303

Merged
merged 1 commit into from Apr 3, 2019

Conversation

Projects
None yet
2 participants
@neubs-bsi
Copy link
Contributor

commented Feb 18, 2019

This pull request introduces two new managers (dotnet and Nuget) that handle .NET dependency management.

Added:

  • Two Managers:
    • DotNet: dotnet manager analyses files ending with ".csproj"
    • Nuget: nuget manager analyses files "package.config"
    • DotNetSupport: is responsible for mapping the dependencies on the model. The information is retrieved from the Nuget API and dependencies are crawled
  • Tests:
    • DotNetSupportTest: tests special cases for dependency resolution
      • coverage is at 96% for the classes and 88% of lines
    • NugetTest: tests a test nuget file included in funTests/assets//projects/synthetics
      • coverage is at 75% for the classes and 91% of lines
    • DotNetTest: tests a test dotnet file included in funTests/assets/projects/synthetics
      • coverage is at 75% for the classes and 91% of lines

Deficencies:

  • most dependencies provided by the nuget API do not contain a repository url and none contain source artifacts. only binary artifacts are provided. So scanning the project is probably not meaningful
  • The dependencies are a bit like NPM, they go very deep. Hence, enormous result files are created and the analysing takes a while, since everything needs to be retrieved from the API.
  • Currently when getting the component information from the Nuget API a range of versions is given for the dependencies and the most recent is chosen. This is not the best solution and should be improved to chose the version a package manager would use.

This change is Reviewable

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch from 18b98ab to 716fc31 Feb 18, 2019

@sschuberth

This comment has been minimized.

Copy link
Collaborator

commented Feb 18, 2019

Thanks @neubs-bsi for the contribution! I see at least one detekt issue being reported in CI. Please run ./gradlew detekt locally and fixup any reported issues to see if CI will pass.

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch 5 times, most recently from f0c2e41 to 4176d93 Feb 18, 2019

@sschuberth

This comment has been minimized.

Copy link
Collaborator

commented Feb 20, 2019

Congrats @neubs-bsi, CI is passing! However, it will probably take us a few days to get started with the review.

@sschuberth sschuberth self-requested a review Feb 20, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch 3 times, most recently from 3f7864b to fe92e69 Feb 21, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch 5 times, most recently from e68c876 to 899c880 Mar 5, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch 2 times, most recently from 1a56ae0 to c3121d8 Mar 13, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch from c3121d8 to 92bd3a4 Mar 25, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch 2 times, most recently from 1fb66b4 to 0676ed6 Apr 3, 2019

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch from 0676ed6 to 19eee0c Apr 3, 2019

@sschuberth

This comment has been minimized.

Copy link
Collaborator

commented Apr 3, 2019

@neubs-bsi don't worry about the failing tests, we need to update some expected results, see #1420. Once that is merged to master, please rebase your PR once more.

@sschuberth

This comment has been minimized.

Copy link
Collaborator

commented Apr 3, 2019

@neubs-bsi, feel free to rebase now!

DotNet: added dotnet and nuget managers including tests
Signed-off-by: Stephanie Neubauer <Stephanie.Neubauer@bosch-si.com>

@neubs-bsi neubs-bsi force-pushed the bsinno:neubs-bsi/addDotNetNugetManager branch from 19eee0c to 9eaf29d Apr 3, 2019

@sschuberth sschuberth merged commit b523174 into heremaps:master Apr 3, 2019

3 checks passed

DCO DCO
Details
Travis CI - Pull Request Build Passed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details

@sschuberth sschuberth changed the title DotNet: added dotnet and nuget managers including tests Add DotNet and NuGet package managers including tests Apr 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.